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

support getLoadContext when using Vite #115

Open
nicksrandall opened this issue May 23, 2024 · 6 comments
Open

support getLoadContext when using Vite #115

nicksrandall opened this issue May 23, 2024 · 6 comments

Comments

@nicksrandall
Copy link

nicksrandall commented May 23, 2024

  • Similar the the Cloudflare preset maintained by remix team, it would be great if the vercelPreset could also accept the getLoadContext function so that the all loaders can get that context.

I don't care how it's implemented, I just need to be able to define my loader context somewhere and use it in a vercel app.

@TooTallNate
Copy link
Member

Did you have a particular use case that you need it for? See #92 for a previous time when this was brought up.

@nicksrandall
Copy link
Author

I'm migrating an existing codebase (~80 routes) and they are all setup to pull resources (like database client, environment variables) from the loader context. We did this, in theory, to make our app more portable across all runtimes/environments. Ironically, its now the only thing preventing us from using vercel.

@nicksrandall
Copy link
Author

If you could show me where this change would live... I'd be happy to send you a PR.

@zipme
Copy link

zipme commented Jun 21, 2024

Same situation here, very desperate

@paul-vd
Copy link

paul-vd commented Jul 23, 2024

Same issue here, we have shared context, and currently we need to make multiple API calls per session to retrieve that context (config related).

@thomasKn
Copy link

thomasKn commented Nov 8, 2024

@TooTallNate any plans on supporting Hydrogen Vite? I know that getLoadContext is already supported in a classic Remix app, but it would be great to also be able to deploy Hydrogen Vite to Vercel.

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

No branches or pull requests

5 participants