import connect from '@aragon/connect'
// Connections should get wrapped in a try / catch to capture connection errors
// Connect to an org through The Graph
const org1 = await connect('org1.aragonid.eth', 'thegraph')
// Specify a different Chain ID
const org3 = await connect('org3.aragonid.eth', 'thegraph', { network: 4 })
// Specify a configuration for the connector
const org3 = await connect('org3.aragonid.eth', [
{ orgSubgraphUrl: 'http://…' },
const org4 = await connect(
// CustomConnector implements IConnector
if (err instanceof ConnectionError) {
console.error('Connection error')