33const path = require ( 'path' ) ;
44const fs = require ( 'fs' ) ;
55const { defineConfig } = require ( '@rspack/cli' ) ;
6- const ForkTsCheckerWebpackPlugin = require ( 'fork- ts-checker-webpack -plugin' ) ;
6+ const { TsCheckerRspackPlugin } = require ( 'ts-checker-rspack -plugin' ) ;
77const dotenv = require ( 'dotenv' ) ;
88const DotenvPlugin = require ( 'dotenv-webpack' ) ;
99const dotenvExpand = require ( 'dotenv-expand' ) ;
@@ -90,10 +90,6 @@ module.exports = (webpackEnv, argv) => {
9090 const useTailwind = fs . existsSync ( path . join ( workspacePath , 'tailwind.config.js' ) ) ;
9191
9292 return defineConfig ( {
93- watchOptions : {
94- // Override the ignore to avoid ignoring node_modules: https://github.com/web-infra-dev/rspack/pull/8645
95- ignored : / [ \\ / ] (?: \. g i t ) [ \\ / ] / ,
96- } ,
9793 mode,
9894 // Logging noise constrained to errors and warnings
9995 stats : 'errors-warnings' , // { logging: 'verbose', timings: true, assets: true },
@@ -106,6 +102,10 @@ module.exports = (webpackEnv, argv) => {
106102 [ workspaceRegistryFile , path . join ( workspacePath , entry . js ) , entry . scss ? path . join ( workspacePath , entry . scss ) : './workspace.scss' ] . filter ( ( v ) => fs . existsSync ( v ) ) ,
107103 ] ) ,
108104 ) ,
105+ watchOptions : {
106+ // Override the ignore to avoid ignoring node_modules: https://github.com/web-infra-dev/rspack/pull/8645
107+ ignored : / [ \\ / ] (?: \. g i t ) [ \\ / ] / ,
108+ } ,
109109 devServer : isEnvDevelopment
110110 ? {
111111 static : path . resolve ( workspacePath , 'bundles' ) ,
@@ -452,7 +452,7 @@ module.exports = (webpackEnv, argv) => {
452452 } ) ,
453453 ) ,
454454 isEnvDevelopment
455- && new ForkTsCheckerWebpackPlugin ( {
455+ && new TsCheckerRspackPlugin ( {
456456 async : isEnvDevelopment ,
457457 typescript : {
458458 diagnosticOptions : {
0 commit comments