-
Notifications
You must be signed in to change notification settings - Fork 153
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: install modules at once #333
Conversation
|
||
addNuxtModule(mod, name) | ||
|
||
const generated = mod.generate().code | ||
latestGenerated = generated // cache the latest generated config |
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.
This needs to put in non-dry condition
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.
Moved!
@@ -54,6 +54,9 @@ export function setupNpmRPC({ nuxt, ensureDevAuthToken }: NuxtDevtoolsServerCont | |||
} | |||
} | |||
|
|||
const installQueue: string[] = [] |
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.
Could use a Set
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.
Yeah, it's been changed to Set.
Resolve #331
Implemented an install queue: I added an installQueue where the module name is pushed into the queue when the module starts installing. When the module installation is complete, the module name is removed from the queue.
Only when all modules are installed is the new configuration written to the file. This prevents an automatic reboot when updating the config, which would result in only one module being installed.