diff --git a/src/data/vue.js/index.js b/src/data/vue.js/index.js new file mode 100644 index 0000000..b25c001 --- /dev/null +++ b/src/data/vue.js/index.js @@ -0,0 +1,3 @@ +export { primaryOptions as optionsFirst } from './primary-options'; +export { secondaryOptions as optionsSecond } from './secondary-options'; +export { tertiaryOptions as optionsThird } from './tertiary-options'; diff --git a/src/data/vue.js/primary-options.js b/src/data/vue.js/primary-options.js new file mode 100644 index 0000000..12f134d --- /dev/null +++ b/src/data/vue.js/primary-options.js @@ -0,0 +1,22 @@ +const options = [ + { value: "create", label: "create" }, + { value: "ui", label: "ui" }, + { value: "serve", label: "serve" }, + { value: "build", label: "build" }, + { value: "lint", label: "lint" }, + { value: "add", label: "add" }, + { value: "invoke", label: "invoke" }, + { value: "inspect", label: "inspect" }, + { value: "install", label: "install" }, + { value: "upgrade", label: "upgrade" }, +]; + +export const primaryOptions = options.sort((x, y) => { + if (x.value < y.value) { + return -1; + } + if (x.value > y.value) { + return 1; + } + return 0; +}); diff --git a/src/data/vue.js/secondary-options.js b/src/data/vue.js/secondary-options.js new file mode 100644 index 0000000..95fc789 --- /dev/null +++ b/src/data/vue.js/secondary-options.js @@ -0,0 +1,142 @@ +export const secondaryOptions = { + create: [ + { + value: "default", + label: "Use default preset", + usage: "npm create vue@latest", + nb: "Creates a project with the latest Vue.js setup.", + }, + { + value: "preset", + label: "Use a specific preset", + usage: "npm create vue@latest -- --preset ", + nb: "Allows using a saved or remote preset for project creation.", + }, + { + value: "inlinePreset", + label: "Use inline preset JSON", + usage: "npm create vue@latest -- --inlinePreset ", + nb: "Enables using an inline JSON string as the preset.", + }, + ], + ui: [ + { + value: "open", + label: "Open Vue GUI", + usage: "vue ui", + nb: "Opens a graphical interface for project management.", + }, + ], + serve: [ + { + value: "port", + label: "Specify port", + usage: "vue-cli-service serve --port ", + nb: "Starts the dev server on the specified port.", + }, + { + value: "host", + label: "Specify host", + usage: "vue-cli-service serve --host ", + nb: "Starts the dev server with the specified host.", + }, + { + value: "open", + label: "Open browser on server start", + usage: "vue-cli-service serve --open", + nb: "Automatically opens the browser when the server starts.", + }, + ], + build: [ + { + value: "dest", + label: "Specify output directory", + usage: "vue-cli-service build --dest ", + nb: "Outputs the build files to the specified directory.", + }, + { + value: "modern", + label: "Build for modern browsers", + usage: "vue-cli-service build --modern", + nb: "Creates a build optimized for modern browsers with auto fallback.", + }, + { + value: "target", + label: "Specify build target", + usage: "vue-cli-service build --target ", + nb: "Sets the build target (e.g., app, lib, wc).", + }, + ], + lint: [ + { + value: "fix", + label: "Automatically fix lint errors", + usage: "vue-cli-service lint --fix", + nb: "Runs the linter and automatically fixes errors.", + }, + { + value: "no-fix", + label: "Do not fix lint errors", + usage: "vue-cli-service lint", + nb: "Runs the linter without fixing errors.", + }, + ], + add: [ + { + value: "plugin", + label: "Add a plugin", + usage: "vue add ", + nb: "Adds a plugin to the existing project.", + }, + ], + invoke: [ + { + value: "plugin", + label: "Invoke a plugin", + usage: "vue invoke ", + nb: "Invokes a plugin generator in an already created project.", + }, + ], + inspect: [ + { + value: "config", + label: "Inspect webpack config", + usage: "vue-cli-service inspect", + nb: "Outputs the internal webpack config for inspection.", + }, + { + value: "rules", + label: "Inspect webpack rules", + usage: "vue-cli-service inspect --rules", + nb: "Displays the webpack rules configuration.", + }, + { + value: "plugins", + label: "Inspect webpack plugins", + usage: "vue-cli-service inspect --plugins", + nb: "Shows the webpack plugins configuration.", + }, + ], + install: [ + { + value: "global", + label: "Install Vue CLI globally", + usage: "npm install -g @vue/cli", + nb: "Installs Vue CLI globally using npm.", + }, + ], + upgrade: [ + { + value: "global", + label: "Upgrade Vue CLI globally", + usage: "npm update -g @vue/cli", + nb: "Upgrades the global installation of Vue CLI.", + }, + { + value: "local", + label: "Upgrade project dependencies", + usage: "vue upgrade", + nb: "Upgrades the Vue CLI service and plugins in the project.", + }, + ], +}; diff --git a/src/data/vue.js/tertiary-options.js b/src/data/vue.js/tertiary-options.js new file mode 100644 index 0000000..bfca5fc --- /dev/null +++ b/src/data/vue.js/tertiary-options.js @@ -0,0 +1,2 @@ +export const tertiaryOptions = { +};