nuxt/cli

`nuxt devtools enable|disable` works only with `--command` flag

Closed this issue · 4 comments

Problem

According to the docs, users can just type nuxi devtools enable to enable devtools in the project. Howerver, after #47 enable/disable flag can only be submitted with --command before the value.

There I need to ask: which way is preferred for the future? Should we change documentation or fix the command itself?

Extra info to help:

1. There is the code, where nuxi expect to have --command flag:
if (!['enable', 'disable'].includes(ctx.args.command)) {

2. There I logged ctx.args:

image

3. There is the run without --command flag, as documented:

image

4. There is the run with --command flag:

image

Still exists, but after nuxt switched to that CLI, problem affects all user, who wants to enable/disable devtools

dycops commented

webstorm64_gItssxBJIR copy
Have the same error

@danielroe should we update the docs to use --command, or change this behaviour ?

I think we should fix the behaviour here so it works as documented.