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

fix(nuxt): Fix dynamic import rollup plugin to work with latest nitro #14243

Merged
merged 1 commit into from
Nov 12, 2024

Conversation

andreiborza
Copy link
Member

@andreiborza andreiborza commented Nov 12, 2024

With nitro 2.10.X the way we imported the server config file and dynamically imported the nitro runtime broke. Instead of landing in the server output entry file, the sdk init and dynamic import landed in the nitro runtime itself.

Based on nitrojs/nitro@8b4a408#diff-e58102d2230f95ddeef2662957b48d847a6e891e354cfd0ae6e2e03ce848d1a2R142 we managed to get back to the original solution by using the \0raw prefix for the entry file.

Note for internal: This does not play well when using symlinks (like yarn link) to link the sdk into a project. Haven't tested how yalc behaves, but tarballs work.

@andreiborza andreiborza requested a review from lforst November 12, 2024 11:37
@andreiborza andreiborza merged commit 0aa7f1d into develop Nov 12, 2024
122 checks passed
@andreiborza andreiborza deleted the ab/nuxt-dynamic-import-fix branch November 12, 2024 11:52
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.

2 participants