Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using V2 and import { graphql } from "gatsby" but still get the warning of using the global graphql #8139

Closed
aleereza opened this issue Sep 14, 2018 · 1 comment · May be fixed by saurabharch/gatsby#2383 or ajesse11x/gatsby#2220

Comments

@aleereza
Copy link

I am using V2 and import graphql from "gatsby" like:
import { graphql } from "gatsby"
but still get this warning:
warning Using the global graphqltag is deprecated, and will not be supported in v3. Import it instead like: import { graphql } from 'gatsby' in file: /project folder/.cache/fragments/image-sharp-fragments.js
could you please tell me how can I fix that?

System:
OS: Linux 4.15 Ubuntu 18.04.1 LTS (Bionic Beaver)
Binaries:
Node: 8.11.4 - /usr/bin/node
npm: 6.4.1 - /usr/bin/npm
npmPackages:
gatsby: ^2.0.0-rc.19 => 2.0.0-rc.19
gatsby-image: ^1.0.55 => 1.0.55
gatsby-plugin-lodash: ^1.0.11 => 1.0.11
gatsby-plugin-sharp: ^1.6.48 => 1.6.48
gatsby-plugin-typography: ^1.7.19 => 1.7.19
gatsby-source-filesystem: ^1.5.39 => 1.5.39
gatsby-transformer-csv: ^1.3.11 => 1.3.11
gatsby-transformer-sharp: ^1.6.27 => 1.6.27

@LekoArts
Copy link
Contributor

LekoArts commented Sep 14, 2018

You need to also update all other gatsby packages to the next version, not only the gatsby one. Then the warning will go away.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants