mirror of
https://github.com/nuxt/nuxt.git
synced 2024-11-22 05:35:13 +00:00
fix(kit,nuxt): ensure webworker types are available
This commit is contained in:
parent
7aae4033b8
commit
6bb24c14cc
@ -191,6 +191,7 @@ export async function _generateTypes (nuxt: Nuxt) {
|
|||||||
'ESNext',
|
'ESNext',
|
||||||
'dom',
|
'dom',
|
||||||
'dom.iterable',
|
'dom.iterable',
|
||||||
|
'webworker',
|
||||||
],
|
],
|
||||||
/* JSX support for Vue */
|
/* JSX support for Vue */
|
||||||
jsx: 'preserve',
|
jsx: 'preserve',
|
||||||
|
@ -112,6 +112,9 @@ export async function initNitro (nuxt: Nuxt & { _nitro?: Nitro }) {
|
|||||||
generateTsConfig: true,
|
generateTsConfig: true,
|
||||||
tsconfigPath: 'tsconfig.server.json',
|
tsconfigPath: 'tsconfig.server.json',
|
||||||
tsConfig: {
|
tsConfig: {
|
||||||
|
compilerOptions: {
|
||||||
|
lib: ['esnext', 'webworker', 'dom.iterable'],
|
||||||
|
},
|
||||||
include: [
|
include: [
|
||||||
join(nuxt.options.buildDir, 'types/nitro-nuxt.d.ts'),
|
join(nuxt.options.buildDir, 'types/nitro-nuxt.d.ts'),
|
||||||
...modules.map(m => join(relativeWithDot(nuxt.options.buildDir, m), 'runtime/server')),
|
...modules.map(m => join(relativeWithDot(nuxt.options.buildDir, m), 'runtime/server')),
|
||||||
|
@ -22,6 +22,7 @@
|
|||||||
/* If your code runs in the DOM: */
|
/* If your code runs in the DOM: */
|
||||||
"lib": [
|
"lib": [
|
||||||
"es2022",
|
"es2022",
|
||||||
|
"webworker",
|
||||||
"dom",
|
"dom",
|
||||||
"dom.iterable"
|
"dom.iterable"
|
||||||
],
|
],
|
||||||
|
Loading…
Reference in New Issue
Block a user