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

Chore: Upgrade GraphiQL to 1.11.4 #273

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

luhagel
Copy link

@luhagel luhagel commented Aug 16, 2022

So, this is the first step on a bigger journey to get the GraphiQL client(s) up to date.

I might need little guidance here and there since I only started wokring with the codebase this evening, and not everything might be optimal ( looking at you, build_asset_path/2)

I also have s semi-functional version of graphiql 2.0 behind a new :beta interface key, but that one needs some more work to get headers to work, and to figure out whether we still need the @absinthe/absinthe-socketlibs or whethercreateGraphiQLFetcher()from@graphiql/toolkit` can solve whatever prompted the creation of that in the first place out of the box now.

Screenshot 2022-08-16 at 04 53 30

If someone has more context/knows, why some decisions were made, that would be greatly appreciated!

This PR

the package still used the 5 year old [email protected], which has a bunch of security issues and could benefit from an update in general (bundle size reduction from react@16 among others). This PR updates graphiql and introduces a way to have two react versions in the asset list, so graphiql-workspace(the :advanced interface) stays functional, since it break with newer react versions.

Next Steps

The next big step would be to get graphiql@2 working, especially with headers and subscriptions. The is quite a bit of plumbing going on atm, which I will need to figure out first, plus the new createGraphiQLFetcher function is not shipped in a browser-compatible version, so we might need another intermediary package... 😨

Once 2.0 ships and graduates beta stage, we can probably remove/alias the :advancedinterface, since graphiql provides those enhancements out of the box. Also,graphiql-workspace` hasn't seen an update in ~4 years, so I wouldn't expect and update on that front.

Happy about any and all feedback !

Upgrades GraphiQL and add the option to have two react versions
@luhagel
Copy link
Author

luhagel commented Sep 20, 2022

@benwilson512 can't request a review formerly yet, would be great if you could take a look at this after your parental leave :)

@aglassman
Copy link

Thanks for your work on this @luhagel, I don't have time to help with the initial work, but can definitely try it when you think it's ready for testing as we are using the old version at the moment.

@drewble
Copy link

drewble commented Dec 15, 2022

Adding to the convo to say this would be a huge boost for Absinthe on my team. Due to the age and limitations of the available GraphiQL interfaces we are currently dropping in Apollo Sandbox. Now that GraphiQL is up to a stable 2.2.0 release it might be reasonable to target an update to 2.x.

@derekbrown
Copy link

Bump. Curious if an upgrade will be merged in the near term?
cc: @benwilson512 @luhagel

@luhagel
Copy link
Author

luhagel commented Oct 7, 2023

Bump. Curious if an upgrade will be merged in the near term? cc: @benwilson512 @luhagel

Probably needs an upgrade at this point, given that graphiql 3 is underway, I'll try and find some time to get this all cleaned up in the next few weeks @derekbrown

@duksis
Copy link

duksis commented Jun 18, 2024

Looking forward to this very needed refresh.

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

Successfully merging this pull request may close these issues.

5 participants