Head's Up! These forums are read-only. All users and content have migrated. Please join us at community.neo4j.com.
03-10-2022 04:07 AM
Hi everyone , I wish you are fine ...
I'm trying to connect my neo4j database with flutter application , after searching here I found that grandstack is the solution .
So I am using graphql_flutter but I have some exceptions that I can't fixed it , as shown in the screenshot
03-11-2022 02:40 PM
Could you please share the GraphQLClient
code that you're using? Also, is the server working as expected? Did you connect successfully to the playground and return the data as expected?
Here's an example of the GraphQLClient
code that I'm talking about.
const clientUri = 'http://ip-adress-here:4001/graphql';
GraphQLClient getClient({String? subscriptionUri, required String tokenId}) {
Link link = HttpLink(
clientUri,
defaultHeaders: {
'Authorization': '''Bearer $tokenId''',
},
);
if (subscriptionUri != null) {
final WebSocketLink websocketLink = WebSocketLink(
subscriptionUri,
config: const SocketClientConfig(
autoReconnect: true,
inactivityTimeout: Duration(seconds: 30),
),
);
link = link.concat(websocketLink);
}
return GraphQLClient(
cache: cache,
link: link,
);
}
03-12-2022 03:29 AM
Yes my server working and I can connected to it from chrome successfully .
Also GraphQL Architect working good unless I change the default database (neo4j) to my database from editor , here he is still loading forever..
03-12-2022 04:53 AM
I have responded to your question on the other thread. Link here for future visitors.
03-12-2022 03:24 AM
final HttpLink httpLink = HttpLink(
final ValueNotifier<GraphQLClient> client = ValueNotifier<GraphQLClient>(
GraphQLClient(
link: httpLink,
cache: GraphQLCache(store: HiveStore()),
),
);
return GraphQLProvider(
client: client,
child: CacheProvider(
child: MaterialApp(
title: 'GraphQLTest',
home: HomePage(),
),
),
);
All the sessions of the conference are now available online