Colum Ferry c1ebcb9129
feat(vite): add support for vite 6 (#29871)
## Current Behavior
Nx currently supports Vite at version 5. Nx does not generate vite
configurations using Vite 6 which has been released.
 

## Expected Behavior
Nx should use Vite 6 for vite projects.

## TODO
- [x] Add Package Update Migrations for Existing Projects
- [x] Add AST migrations to handle breaking change in resolve.extensions
- [x] Add migration to install `jsx` or `jiti` to handle processing TS
postcss config files
2025-02-11 11:28:23 -05:00

55 lines
1.6 KiB
JSON

{
"name": "init",
"factory": "./src/generators/init/init#initGeneratorInternal",
"schema": {
"cli": "nx",
"title": "Initialize Vite in the workspace.",
"description": "Initialize Vite in the workspace.",
"$id": "init-vite-plugin",
"type": "object",
"properties": {
"skipFormat": {
"description": "Skip formatting files.",
"type": "boolean",
"default": false
},
"skipPackageJson": {
"description": "Do not add dependencies to `package.json`.",
"type": "boolean",
"default": false
},
"setupPathsPlugin": {
"type": "boolean",
"description": "Updates vite config files to enable support for workspace libraries via the nxViteTsPaths plugin.",
"default": false
},
"keepExistingVersions": {
"type": "boolean",
"x-priority": "internal",
"description": "Keep existing dependencies versions",
"default": false
},
"updatePackageScripts": {
"type": "boolean",
"x-priority": "internal",
"description": "Update `package.json` scripts with inferred targets",
"default": false
},
"useViteV5": {
"type": "boolean",
"description": "Use Vite v5",
"default": false,
"x-priority": "internal",
"hidden": true
}
},
"presets": []
},
"description": "Initialize Vite in the workspace.",
"aliases": ["ng-add"],
"hidden": true,
"implementation": "/packages/vite/src/generators/init/init#initGeneratorInternal.ts",
"path": "/packages/vite/src/generators/init/schema.json",
"type": "generator"
}