graphql-kit / graphql-voyager

🛰️ Represent any GraphQL API as an interactive graph
https://graphql-kit.com/graphql-voyager/
MIT License
7.81k stars 516 forks source link

Latest NPM publish does not include render-voyager-page.js fix from #357 #372

Open traverse1984 opened 1 year ago

traverse1984 commented 1 year ago

Hi,

I stumbled across Voyager for the first time today - great work!

Setting up the express middleware as per the readme leaves a dead "Loading" page in the browser. I can see this issue has already been fixed in #357 but the version hosted on NPM does not include this fix. I've patched my local version manually so I am able to use the software in the meantime.

I'm raising this issue primarily to draw attention as it affects all of the middleware offered - I think that's a big deal and would be considering a patch release as soon as practical.

Thanks again, Matt

BabakScript commented 1 year ago

I have the same issue with version 2 and it is stuck in the "Loading" mode and the middleware version in Express.js is not working anymore so I have to downgrade to 1.3.0 for now. This is my code:

app.use(
  "/voyager",
  voyagerMiddleware({
    endpointUrl: env.endpoint
  }),
);
traverse1984 commented 1 year ago

I have the same issue with version 2 and it is stuck in the "Loading" mode and the middleware version in Express.js is not working anymore so I have to downgrade to 1.3.0 for now. This is my code:


app.use(

  "/voyager",

  voyagerMiddleware({

    endpointUrl: env.endpoint

  }),

);

It's relatively easy to fix locally if you follow the issue I linked... you can just replace a single file in your node_modules.

BabakScript commented 1 year ago

I have the same issue with version 2 and it is stuck in the "Loading" mode and the middleware version in Express.js is not working anymore so I have to downgrade to 1.3.0 for now. This is my code:


app.use(

  "/voyager",

  voyagerMiddleware({

    endpointUrl: env.endpoint

  }),

);

It's relatively easy to fix locally if you follow the issue I linked... you can just replace a single file in your node_modules.

Thanks but I'm using voyagerMiddleware in my express app and deploying it to the server, so I'm not using it for the local development.

traverse1984 commented 1 year ago

Thanks but I'm using voyagerMiddleware in my express app and deploying it to the server, so I'm not using it for the local development.

So am I, you can still fix as above.

BabakScript commented 1 year ago

Thanks but I'm using voyagerMiddleware in my express app and deploying it to the server, so I'm not using it for the local development.

So am I, you can still fix as above.

Can you share more details on how did you patch it?

traverse1984 commented 1 year ago

Copy the file from the issue I linked in my first post into the node_modules/graphql-voyager folder in the correct location.

It's not a permanent solution because if you install somewhere else you need to update the file again... however for my purposes it was suitable.

kenstott commented 1 year ago

Any chance this fix will get pushed sometime soon?