Questions tagged [apollo-boost]
28 questions
9
votes
2 answers
difference between @apollo/client , apollo-client and apollo boost
I am implementing using @apollo/client, but i do not see any complete example of @apollo/client with react.
If i search i get example with apollo-client and apollo boost.
What is the difference between all 3.
I understand @apollo/client is the new…

apps
- 313
- 1
- 7
- 17
5
votes
1 answer
react with GraphQL Clients
Using React with GraphQL clients like Apollo Client is a good idea? The same results i can achieve with react and new Context API.
Basically i can consume GraphQL APIs using axios or any other libraries like this. And for state management i can use…

Roopak Puthenveettil
- 1,387
- 2
- 13
- 27
4
votes
1 answer
ApolloClient: Invariant Violation 1 – setup apollo client properly
I am new to GraphQL and Apollo and I am really struggling with setting up an apolloClient in node.js.
First I want to mention that I sucessfully set up an apollo client within nuxt using nuxt's apollo module.
So I am completely sure that my endpoint…

Merc
- 4,241
- 8
- 52
- 81
3
votes
2 answers
Extensions not returned in GraphQL query results
I'm creating an Apollo Client like this:
var { ApolloClient } = require("apollo-boost");
var { InMemoryCache } = require('apollo-cache-inmemory');
var { createHttpLink } = require('apollo-link-http');
var { setContext } =…

RaphArbuz
- 869
- 1
- 9
- 19
3
votes
2 answers
ApolloClient from apollo-boost attemped to assign to readonly property
I'm working with react-native, and trying to load Apollo from apollo-boost. When I attempt to import the client, I get the error message "Attempted to assign to readonly property." I'm not sure how to work around this, and it seems from the stack…

psion
- 748
- 1
- 6
- 17
3
votes
0 answers
Vue Apollo: How to display Mysql data in VueJS frontend by GraphQL
I am new developer in VueJS and NodeJS development.
I am using apollo-boost,graphql,vue-apollo for front end section and
I am using express-graphql, express, graphql, knex, MySQL for backend section.
After running the backend section, I am getting…

Rohit Vyas
- 790
- 6
- 16
2
votes
1 answer
Apollo Network (Bad Request) error not caught in apollo-link-error
Sending a mutation with a bad set of variables (on purpose in this case) results in errors being thrown in the console, and the apollo-link-error link not picking up the error. Additionally, the mutation loading state is stuck as 'loading' and not…

goofiw
- 607
- 5
- 16
2
votes
1 answer
Cant Set Apollo Local State with nested values
I'm testing out Apollo Graphql with React and I'm trying to update the local state with Apollo Graphql with a nested object. I'm running into an issue. The data returns a null value and does not even return the value I set as a default. The only…

Chris Bryant
- 123
- 7
2
votes
1 answer
How to pass value to AppolloBoost client from Redux?
I want to pass a token stored in redux to the ApolloBoost Cliet. How do you acheive this using redux-react-hook library??
import ApolloBoost from 'apollo-boost'
const client = new ApolloBoost({
uri: 'https://api.github.com/graphql',
request:…

Dongyob
- 87
- 2
- 8
2
votes
3 answers
Apollo boost - __typename in query prevent new mutation
I have a problem in my meteor/react/apollo (with boost) project. When I query data from the server, it adds __typename to every object and subobject in my query but it my case it creates a major issue as I normally reuse these data to send them to…

Ivo
- 2,308
- 1
- 13
- 28
1
vote
1 answer
Error: ENOENT: no such file or directory, open
I am learning apollo. When I run my code it showing this error on my browser I don't know if it is my browser's problem. can anyone help me fix this
Error message
./node_modules/@apollo/client/node_modules/optimism/lib/bundle.esm.js
Error: ENOENT:…

BIJITH JITHU
- 41
- 1
- 8
1
vote
1 answer
Apollo Client TypeError: Object is not function
currently I'm facing a problem while querying my Nexus GraphQL backend. In my frontend I use Apollo-boost (Apollo Client) to run queries. I tried to get data from backend in a simple example but it's not working and I can't find the problem. Am I…

wyndham007
- 181
- 3
- 14
1
vote
2 answers
Dynamic filter operator in GraphQL using Apollo (in a React app)
I'm using Apollo to make requests to my GraphQL server.
My query is like below:
export const QUERY_ITEMS = gql`
query get_items($date: date) {
items(where: {date: {_eq: $date}}) {
name
}
}
`;
const {data} =…

7ball
- 2,183
- 4
- 26
- 61
1
vote
1 answer
How to run external query through local resolver in Apollo Client
I have one more question. On my server I have something like:
extend type Query {
login (input: LoginInput!): Response
}
On the client, I am trying to make the query:
query Login ($input: LoginInput!) {
login (input: $input) {
login…

Dominik Teiml
- 505
- 1
- 4
- 12
1
vote
0 answers
How to return distinct data using gql from apollo-boost
I am working with a React component implemented with TypeScript where I am querying some data using gql from apollo-boost library. First time user so have little knowledge.
const GET_COUNTRIES = gql`
query GET_COUNTRIES {
users {
…

PineCone
- 2,193
- 12
- 37
- 78