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: attempts to dynamically load config for getPayloadHMR #5875

Closed
wants to merge 1 commit into from

Conversation

jmikrut
Copy link
Member

@jmikrut jmikrut commented Apr 16, 2024

Attempts to expose a utility that loads the config within a package that is marked as serverComponentsExternalPackages, so we can avoid having any of the config's client components included in the client-side JS bundle that Next.js produces.

Related issue:
vercel/next.js#50285

@jmikrut
Copy link
Member Author

jmikrut commented Apr 16, 2024

This PR likely won't work because if we dynamically load the config, we will then need to transpile it on-the-fly even in production. Alternatively, we could build a production version of the config, but that's adding a lot of complexity.

Going to investigate some other alternative approaches.

@jmikrut jmikrut closed this Apr 16, 2024
@jmikrut jmikrut deleted the feat/config-loader branch December 20, 2024 20:25
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.

1 participant