-
-
Notifications
You must be signed in to change notification settings - Fork 4.8k
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
feat(nuxt,schema): add new appId
option and improve chunk determinism
#27258
Conversation
Run & review this pull request in StackBlitz Codeflow. |
appId
option and improve chunk determinism
* For multi-app projects, the unique name of the Nuxt application. | ||
*/ | ||
appId: { | ||
$resolve: (val: string) => val ?? 'nuxt-app', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't we have a risk of name collision in case appId
is not filled in in user land and default value nuxt-app
is used multiple times?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
well, I would add Symbol('nuxt-app') so that the name does not conflict
🔗 Linked issue
📚 Description
This adds a new
appId
option and passes bothappId
andbuildId
via runtimeConfig. This means we don't have all chunk hashes changing on every build. (Caused by entry file chunk hash changing with new buildId, and then every other file that imported the entry file changing because that file name changed.)