flask-graphql icon indicating copy to clipboard operation
flask-graphql copied to clipboard

which graphiql version is using?

Open qinst64 opened this issue 4 years ago • 2 comments

I have Flask-GraphQL==2.0.1 installed and inside Chrome it is requiring dependencies like

http://cdn.jsdelivr.net/npm/[email protected]/graphiql.min.js note: currently the latest version in jsdelivr is 1.0.6

however the github readme says

graphiql_version: The graphiql version to load. Defaults to "1.0.3".

reallly? If I set graphiql_version=1.0.3 explicitly, then Chrome throws error

Uncaught Error: GraphiQL 0.18.0 and after is not compatible with React 15 or below

I did not find anywhere the render_graphiql.py set the variable to "1.0.3" In my local drive is GRAPHIQL_VERSION = '0.11.11'; and gitlab GRAPHIQL_VERSION = '0.7.1'

qinst64 avatar Nov 16 '20 09:11 qinst64

It's because you are reading the readme for the master branch, but that is somewhat newer than the latest PyPI release, which is v2.0.1. This version used a much older version of React and a much older default GraphiQL. You can in theory upgrade a few of these packages to the github master branch but I don't recommend it for dependency hell reasons. I think we just have to wait until this repo, and graphql-server publish their 3.x.x versions and everything will work.

multimeric avatar Jul 27 '21 02:07 multimeric

The best we can do using stable versions is graphiql_version="0.17.5". Newer versions aren't supported because of the old React version.

multimeric avatar Jul 27 '21 03:07 multimeric