d4rekanguok / gatsby-typescript

Alternative typescript support plugin for Gatsbyjs. Aims to make using typescript in Gatsby as painless as possible
MIT License
122 stars 18 forks source link

[docs] Advice users to install `graphql` directly to avoid walls of peer deps warning #7

Open d4rekanguok opened 5 years ago

d4rekanguok commented 5 years ago

When users install the plugin to their site, they'll met with 10s of dependencies warnings for graphql. We have to use Gatsby's own graphql (gatsby/graphql). I'm not sure how to fix this?

Here's the messages:

Dereks-MacBook-Pro-2:test-ts derek$ yarn add gatsby-plugin-ts
yarn add v1.16.0
[1/4] 🔍  Resolving packages...
[2/4] 🚚  Fetching packages...
[3/4] 🔗  Linking dependencies...
warning "gatsby-plugin-ts > graphql-toolkit > graphql-import@0.7.1" has unmet peer dependency "graphql@^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0".
warning "gatsby-plugin-ts > @graphql-codegen/core@1.3.1" has unmet peer dependency "graphql@^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0".
warning "gatsby-plugin-ts > graphql-toolkit@0.2.14" has unmet peer dependency "graphql@^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0".
warning "gatsby-plugin-ts > @graphql-codegen/core > @graphql-codegen/plugin-helpers@1.3.1" has unmet peer dependency "graphql@^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0".
warning "gatsby-plugin-ts > @graphql-codegen/typescript > @graphql-codegen/visitor-plugin-common@1.3.1" has unmet peer dependency "graphql@^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0".
warning "gatsby-plugin-ts > graphql-toolkit > graphql-tools@4.0.4" has unmet peer dependency "graphql@^0.13.0 || ^14.0.0".
warning "gatsby-plugin-ts > @graphql-codegen/typescript > @graphql-codegen/visitor-plugin-common > graphql-tag@2.10.1" has unmet peer dependency "graphql@^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0".
warning "gatsby-plugin-ts > graphql-toolkit > graphql-tools > apollo-link@1.2.12" has unmet peer dependency "graphql@^0.11.3 || ^0.12.3 || ^0.13.0 || ^14.0.0".
warning "gatsby-plugin-ts > graphql-toolkit > graphql-tools > apollo-utilities@1.3.2" has unmet peer dependency "graphql@^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0".
d4rekanguok commented 4 years ago

The graphql peer dependencies warning is back (#33) and is worse than ever...

warning " > @graphql-toolkit/code-file-loader@0.9.7" has unmet peer dependency "graphql@^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0".
warning "@graphql-toolkit/code-file-loader > @graphql-toolkit/common@0.9.7" has unmet peer dependency "graphql@^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0".
warning "@graphql-toolkit/code-file-loader > @graphql-toolkit/graphql-tag-pluck@0.9.7" has unmet peer dependency "graphql@^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0".
warning "@graphql-toolkit/code-file-loader > @graphql-toolkit/common > @ardatan/graphql-tools@4.1.0" has unmet peer dependency "graphql@^0.13.0 || ^14.0.0".
warning "@graphql-toolkit/code-file-loader > @graphql-toolkit/common > @ardatan/graphql-tools > apollo-link@1.2.13" has unmet peer dependency "graphql@^0.11.3 || ^0.12.3 || ^0.13.0 || ^14.0.0".
warning "@graphql-toolkit/code-file-loader > @graphql-toolkit/common > @ardatan/graphql-tools > apollo-utilities@1.3.3" has unmet peer dependency "graphql@^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0".
warning "gatsby-plugin-typescript > @babel/plugin-proposal-nullish-coalescing-operator@7.7.4" has unmet peer dependency "@babel/core@^7.0.0-0".
warning "gatsby-plugin-typescript > @babel/plugin-proposal-optional-chaining@7.7.5" has unmet peer dependency "@babel/core@^7.0.0-0".
warning "gatsby-plugin-graphql-codegen > @graphql-toolkit/core@0.9.7" has unmet peer dependency "graphql@^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0".
warning "gatsby-plugin-graphql-codegen > @graphql-codegen/typescript@1.12.1" has unmet peer dependency "graphql@^0.12.0 || ^0.13.0 || ^14.0.0".
warning "gatsby-plugin-graphql-codegen > @graphql-codegen/core@1.12.1" has unmet peer dependency "graphql@^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0".
warning "gatsby-plugin-graphql-codegen > @graphql-codegen/typescript-operations@1.12.1" has unmet peer dependency "graphql@^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0".
warning "gatsby-plugin-graphql-codegen > @graphql-toolkit/core > @graphql-toolkit/schema-merging@0.9.7" has unmet peer dependency "graphql@^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0".
warning "gatsby-plugin-graphql-codegen > @graphql-codegen/typescript > @graphql-codegen/plugin-helpers@1.12.1" has unmet peer dependency "graphql@^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0".
warning "gatsby-plugin-graphql-codegen > @graphql-codegen/typescript > @graphql-codegen/visitor-plugin-common@1.12.1" has unmet peer dependency "graphql@^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0".
warning "gatsby-plugin-graphql-codegen > @graphql-codegen/typescript > @graphql-codegen/visitor-plugin-common > graphql-tag@2.10.1" has unmet peer dependency "graphql@^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0".
warning "gatsby-plugin-graphql-codegen > @graphql-codegen/typescript > @graphql-codegen/visitor-plugin-common > @graphql-toolkit/relay-operation-optimizer@0.9.7" has unmet peer dependency "graphql@^0.8.0 || ^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0 || ^0.13.0 || ^14.0.0".
warning "gatsby-plugin-graphql-codegen > @graphql-codegen/typescript > @graphql-codegen/visitor-plugin-common > @graphql-toolkit/relay-operation-optimizer > relay-compiler@8.0.0" has unmet peer dependency "graphql@^14.2.0".
d4rekanguok commented 4 years ago

perhaps advice users to install graphql directly. Otherwise there seems to be no way to supress this warning.

mrackwitz commented 4 years ago

Maybe this could be also done via a postinstall script? That should make it very obvious.