feat: hide panel by default when not explicit enabled #440
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
When we ship DevTools by default in Nuxt 3, we want to minimize the distribution for regular development workflow as much as possible. In that case, we don't want all users to get the floating panel in their apps without knowing the existence of Nuxt DevTools.
In this PR, we make the panel hide by default, except when
devtools: { enabled: true }
ormodules: ['@nuxt/devtools']
is presented in the config (indicate that the users are aware of and want to use devtools).Combining with 97b3e18, we are showing the hint in both the terminal and browser console. For the first time a user opens up DevTools, a welcome page will be displayed and ask to turn on the floating panel.