mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-11 08:33:53 +00:00
fix(nuxt): add @types/node
as a peerDependency (#20025)
This commit is contained in:
parent
b8cdef69cd
commit
4d75540655
@ -8,7 +8,7 @@ Nuxt 3 is fully typed and provides helpful shortcuts to ensure you have access t
|
||||
|
||||
## Type-checking
|
||||
|
||||
By default, Nuxt doesn't check types when you run `nuxi dev` or `nuxi build`, for performance reasons. However, you can enable type-checking at build or development time by installing `@types/node`, `vue-tsc` and `typescript` as devDependencies and either enabling [the `typescript.typeCheck` option in your `nuxt.config` file](/docs/api/configuration/nuxt-config#typescript) or [manually checking your types with nuxi](/docs/api/commands/typecheck).
|
||||
By default, Nuxt doesn't check types when you run `nuxi dev` or `nuxi build`, for performance reasons. However, you can enable type-checking at build or development time by installing `vue-tsc` and `typescript` as devDependencies and either enabling [the `typescript.typeCheck` option in your `nuxt.config` file](/docs/api/configuration/nuxt-config#typescript) or [manually checking your types with nuxi](/docs/api/commands/typecheck).
|
||||
|
||||
```bash
|
||||
yarn nuxi typecheck
|
||||
|
@ -18,5 +18,5 @@ Option | Default | Description
|
||||
This command sets `process.env.NODE_ENV` to `production`. To override, define `NODE_ENV` in a `.env` file or as a command-line argument.
|
||||
|
||||
::alert
|
||||
You can also enable type-checking at build or development time by installing `@types/node`, `typescript` and `vue-tsc` as devDependencies and enabling [the `typescript.typeCheck` option in your `nuxt.config` file](/docs/api/configuration/nuxt-config#typescript).
|
||||
You can also enable type-checking at build or development time by installing `typescript` and `vue-tsc` as devDependencies and enabling [the `typescript.typeCheck` option in your `nuxt.config` file](/docs/api/configuration/nuxt-config#typescript).
|
||||
::
|
||||
|
@ -109,6 +109,9 @@
|
||||
"@types/hash-sum": "^1.0.0",
|
||||
"unbuild": "latest"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"@types/node": "^14.18.0 || ^16.10.0 || ^17.0.0 || ^18.0.0 || ^19.0.0"
|
||||
},
|
||||
"engines": {
|
||||
"node": "^14.18.0 || ^16.10.0 || ^17.0.0 || ^18.0.0 || ^19.0.0"
|
||||
}
|
||||
|
@ -536,6 +536,9 @@ importers:
|
||||
'@nuxt/vite-builder':
|
||||
specifier: workspace:*
|
||||
version: link:../vite
|
||||
'@types/node':
|
||||
specifier: ^14.18.0 || ^16.10.0 || ^17.0.0 || ^18.0.0 || ^19.0.0
|
||||
version: 18.15.11
|
||||
'@unhead/ssr':
|
||||
specifier: ^1.1.25
|
||||
version: 1.1.25
|
||||
|
Loading…
Reference in New Issue
Block a user