The Nx plugin for Vue.
Setting Up @nx/vue
Generating a new Workspace
To create a new workspace with Vue, run npx create-nx-workspace@latest --preset=vue
.
For a full tutorial experience, follow the Vue Standalone Tutorial
Installation
Keep Nx Package Versions In SyncMake sure to install the @nx/vue
version that matches the version of nx
in your repository. If the version numbers get out of sync, you can encounter some difficult to debug errors. You can fix Nx version mismatches with this recipe.
In any Nx workspace, you can install @nx/vue
by running the following command:
❯
nx add @nx/vue
This will install the correct version of @nx/vue
.
Using the @nx/vue Plugin
Generate a new project using Vue
To generate a Vue application, run the following:
❯
nx g @nx/vue:app my-app
To generate a Vue library, run the following:
❯
nx g @nx/vue:lib my-lib