Skip to content

Commit f083655

Browse files
authored
chore(deps): update dependency fork-ts-checker-webpack-plugin to v5 (#391)
1 parent 09ee1a4 commit f083655

File tree

5 files changed

+44
-34
lines changed

5 files changed

+44
-34
lines changed

packages/typescript-build/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
"dependencies": {
1818
"@nuxt/types": "0.7.9",
1919
"consola": "^2.14.0",
20-
"fork-ts-checker-webpack-plugin": "^4.1.6",
20+
"fork-ts-checker-webpack-plugin": "^5.0.6",
2121
"ts-loader": "^7.0.5",
2222
"typescript": "~3.9"
2323
},

packages/typescript-build/src/index.ts

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import path from 'path'
22
import consola from 'consola'
33
import { Module } from '@nuxt/types'
44
import { Options as TsLoaderOptions } from 'ts-loader'
5-
import { Options as TsCheckerOptions } from 'fork-ts-checker-webpack-plugin'
5+
import { ForkTsCheckerWebpackPluginOptions as TsCheckerOptions } from 'fork-ts-checker-webpack-plugin/lib/ForkTsCheckerWebpackPluginOptions'
66
import { RuleSetUseItem } from 'webpack'
77

88
declare module '@nuxt/types' {
@@ -17,7 +17,7 @@ export interface Options {
1717
ts?: Partial<TsLoaderOptions>
1818
tsx?: Partial<TsLoaderOptions>
1919
}
20-
typeCheck?: Partial<TsCheckerOptions> | boolean
20+
typeCheck?: TsCheckerOptions | boolean
2121
}
2222

2323
const defaults: Options = {
@@ -75,11 +75,14 @@ const tsModule: Module<Options> = function (moduleOptions) {
7575
if (options.typeCheck && isClient && !isModern) {
7676
const ForkTsCheckerWebpackPlugin = require(this.nuxt.resolver.resolveModule('fork-ts-checker-webpack-plugin'))
7777
config.plugins!.push(new ForkTsCheckerWebpackPlugin(Object.assign({
78-
vue: true,
79-
tsconfig: path.resolve(this.options.rootDir!, 'tsconfig.json'),
80-
formatter: 'codeframe',
78+
typescript: {
79+
configFile: path.resolve(this.options.rootDir!, 'tsconfig.json'),
80+
extensions: {
81+
vue: true
82+
}
83+
},
8184
logger: consola.withScope('nuxt:typescript')
82-
}, options.typeCheck)))
85+
} as TsCheckerOptions, options.typeCheck)))
8386
}
8487
})
8588
}
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
declare module '*.vue' {
2+
import Vue from 'vue'
3+
export default Vue
4+
}

packages/typescript-build/test/fixture/tsconfig.json

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
{
22
"compilerOptions": {
3-
"target": "es2018",
4-
"module": "esnext",
5-
"moduleResolution": "node",
3+
"target": "ES2018",
4+
"module": "ESNext",
5+
"moduleResolution": "Node",
66
"lib": [
7-
"esnext",
8-
"esnext.asynciterable",
9-
"dom"
7+
"ESNext",
8+
"ESNext.AsyncIterable",
9+
"DOM"
1010
],
1111
"esModuleInterop": true,
1212
"allowJs": true,

yarn.lock

Lines changed: 24 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
# yarn lockfile v1
33

44

5-
"@babel/code-frame@^7.0.0", "@babel/code-frame@^7.5.5", "@babel/code-frame@^7.8.3":
5+
"@babel/code-frame@^7.0.0", "@babel/code-frame@^7.8.3":
66
version "7.8.3"
77
resolved "https://registry.yarnpkg.com/@babel/code-frame/-/code-frame-7.8.3.tgz#33e25903d7481181534e12ec0a25f16b6fcf419e"
88
integrity sha512-a9gxpmdXtZEInkCSHUJDLHZVBgb1QS0jhss4cPP93EW7s+uC5bikET2twEF3KV+7rDblJcmNvTR7VJejqd2C2g==
@@ -6241,18 +6241,21 @@ forever-agent@~0.6.1:
62416241
resolved "https://registry.yarnpkg.com/forever-agent/-/forever-agent-0.6.1.tgz#fbc71f0c41adeb37f96c577ad1ed42d8fdacca91"
62426242
integrity sha1-+8cfDEGt6zf5bFd60e1C2P2sypE=
62436243

6244-
fork-ts-checker-webpack-plugin@^4.1.6:
6245-
version "4.1.6"
6246-
resolved "https://registry.yarnpkg.com/fork-ts-checker-webpack-plugin/-/fork-ts-checker-webpack-plugin-4.1.6.tgz#5055c703febcf37fa06405d400c122b905167fc5"
6247-
integrity sha512-DUxuQaKoqfNne8iikd14SAkh5uw4+8vNifp6gmA73yYNS6ywLIWSLD/n/mBzHQRpW3J7rbATEakmiA8JvkTyZw==
6244+
fork-ts-checker-webpack-plugin@^5.0.6:
6245+
version "5.0.6"
6246+
resolved "https://registry.yarnpkg.com/fork-ts-checker-webpack-plugin/-/fork-ts-checker-webpack-plugin-5.0.6.tgz#02af713af02e47b338a3992279209bc65d34c773"
6247+
integrity sha512-8h4S7WANr69Resw+tMd5U23xdbVPsT+VOeMKQhUaKhkGeMm0fNf7ObJPP81WG+tsmy4LK4ayIf0JXBY+hy6vMw==
62486248
dependencies:
6249-
"@babel/code-frame" "^7.5.5"
6249+
"@babel/code-frame" "^7.8.3"
62506250
chalk "^2.4.1"
6251-
micromatch "^3.1.10"
6251+
cosmiconfig "^6.0.0"
6252+
deepmerge "^4.2.2"
6253+
fs-extra "^9.0.0"
6254+
memfs "^3.1.2"
62526255
minimatch "^3.0.4"
6256+
schema-utils "1.0.0"
62536257
semver "^5.6.0"
62546258
tapable "^1.0.0"
6255-
worker-rpc "^0.1.0"
62566259

62576260
form-data@~2.3.2:
62586261
version "2.3.3"
@@ -6321,6 +6324,11 @@ fs-minipass@^2.0.0:
63216324
dependencies:
63226325
minipass "^3.0.0"
63236326

6327+
6328+
version "1.0.1"
6329+
resolved "https://registry.yarnpkg.com/fs-monkey/-/fs-monkey-1.0.1.tgz#4a82f36944365e619f4454d9fff106553067b781"
6330+
integrity sha512-fcSa+wyTqZa46iWweI7/ZiUfegOZl0SG8+dltIwFXo7+zYU9J9kpS3NB6pZcSlJdhvIwp81Adx2XhZorncxiaA==
6331+
63246332
fs-write-stream-atomic@^1.0.8:
63256333
version "1.0.10"
63266334
resolved "https://registry.yarnpkg.com/fs-write-stream-atomic/-/fs-write-stream-atomic-1.0.10.tgz#b47df53493ef911df75731e70a9ded0189db40c9"
@@ -8563,6 +8571,13 @@ mem@^6.0.1:
85638571
map-age-cleaner "^0.1.3"
85648572
mimic-fn "^3.0.0"
85658573

8574+
memfs@^3.1.2:
8575+
version "3.2.0"
8576+
resolved "https://registry.yarnpkg.com/memfs/-/memfs-3.2.0.tgz#f9438e622b5acd1daa8a4ae160c496fdd1325b26"
8577+
integrity sha512-f/xxz2TpdKv6uDn6GtHee8ivFyxwxmPuXatBb1FBwxYNuVpbM3k/Y1Z+vC0mH/dIXXrukYfe3qe5J32Dfjg93A==
8578+
dependencies:
8579+
fs-monkey "1.0.1"
8580+
85668581
memory-fs@^0.4.1:
85678582
version "0.4.1"
85688583
resolved "https://registry.yarnpkg.com/memory-fs/-/memory-fs-0.4.1.tgz#3a9a20b8462523e447cfbc7e8bb80ed667bfc552"
@@ -8671,11 +8686,6 @@ methods@~1.1.2:
86718686
resolved "https://registry.yarnpkg.com/methods/-/methods-1.1.2.tgz#5529a4d67654134edcc5266656835b0f851afcee"
86728687
integrity sha1-VSmk1nZUE07cxSZmVoNbD4Ua/O4=
86738688

8674-
microevent.ts@~0.1.1:
8675-
version "0.1.1"
8676-
resolved "https://registry.yarnpkg.com/microevent.ts/-/microevent.ts-0.1.1.tgz#70b09b83f43df5172d0205a63025bce0f7357fa0"
8677-
integrity sha512-jo1OfR4TaEwd5HOrt5+tAZ9mqT4jmpNAusXtyfNzqVm9uiSYFZlKM1wYL4oU7azZW/PxQW53wM0S6OR1JHNa2g==
8678-
86798689
[email protected], micromatch@^4.0.0, micromatch@^4.0.2:
86808690
version "4.0.2"
86818691
resolved "https://registry.yarnpkg.com/micromatch/-/micromatch-4.0.2.tgz#4fcb0999bf9fbc2fcbdd212f6d629b9a56c39259"
@@ -11385,7 +11395,7 @@ saxes@^5.0.0:
1138511395
dependencies:
1138611396
xmlchars "^2.2.0"
1138711397

11388-
schema-utils@^1.0.0:
11398+
schema-utils@1.0.0, schema-utils@^1.0.0:
1138911399
version "1.0.0"
1139011400
resolved "https://registry.yarnpkg.com/schema-utils/-/schema-utils-1.0.0.tgz#0b79a93204d7b600d4b2850d1f66c2a34951c770"
1139111401
integrity sha512-i27Mic4KovM/lnGsy8whRCHhc7VicJajAjTrYg11K9zfZXnYIt4k5F+kZkwjnrhKzLic/HLU4j11mjsz2G/75g==
@@ -13287,13 +13297,6 @@ worker-farm@^1.7.0:
1328713297
dependencies:
1328813298
errno "~0.1.7"
1328913299

13290-
worker-rpc@^0.1.0:
13291-
version "0.1.1"
13292-
resolved "https://registry.yarnpkg.com/worker-rpc/-/worker-rpc-0.1.1.tgz#cb565bd6d7071a8f16660686051e969ad32f54d5"
13293-
integrity sha512-P1WjMrUB3qgJNI9jfmpZ/htmBEjFh//6l/5y8SD9hg1Ef5zTTVVoRjTrTEzPrNBQvmhMxkoTsjOXN10GWU7aCg==
13294-
dependencies:
13295-
microevent.ts "~0.1.1"
13296-
1329713300
wrap-ansi@^5.1.0:
1329813301
version "5.1.0"
1329913302
resolved "https://registry.yarnpkg.com/wrap-ansi/-/wrap-ansi-5.1.0.tgz#1fd1f67235d5b6d0fee781056001bfb694c03b09"

0 commit comments

Comments
 (0)