11import { define } from 'rstack' ;
22
3- define . lint ( ( { globals, js, rstestPlugin, ts } ) => [
4- {
5- ignores : [
6- // TypeScript does not support source phase imports syntax
7- 'tests/integration/wasm/static-source/src/utils.js' ,
8- 'tests/integration/wasm-inline/basic/src/source.js' ,
9- ] ,
10- } ,
3+ define . lint ( ( { globalIgnores, globals, js, rstestPlugin, ts } ) => [
4+ globalIgnores ( [
5+ // TypeScript does not support source phase imports syntax
6+ 'tests/integration/wasm/static-source/src/utils.js' ,
7+ 'tests/integration/wasm-inline/basic/src/source.js' ,
8+ ] ) ,
119 js . configs . recommended ,
1210 ts . configs . recommended ,
1311 {
1412 languageOptions : {
1513 parserOptions : {
16- project : [
17- './packages/*/tsconfig.json' ,
18- './packages/core/tests/tsconfig.json' ,
19- './examples/*/tsconfig.json' ,
20- './examples/module-federation/*/tsconfig.json' ,
21- './tests/tsconfig.json' ,
22- './tests/scripts/tsconfig.json' ,
23- './tests/type-tests/*/tsconfig.json' ,
24- ] ,
14+ projectService : true ,
2515 } ,
2616 } ,
2717 rules : {
@@ -31,7 +21,7 @@ define.lint(({ globals, js, rstestPlugin, ts }) => [
3121 } ,
3222 } ,
3323 {
34- files : [ '**/*.js' , '**/*. jsx' , '**/*. mjs' , '**/*. cjs'] ,
24+ files : [ '**/*.{js, jsx, mjs, cjs} ' ] ,
3525 languageOptions : {
3626 globals : {
3727 ...globals . node ,
@@ -53,16 +43,24 @@ define.lint(({ globals, js, rstestPlugin, ts }) => [
5343 'rstest/expect-expect' : [
5444 'warn' ,
5545 {
56- assertFunctionNames : [
57- 'expect' ,
58- 'assert' ,
59- 'expect*' ,
60- 'createAndValidate' ,
61- ] ,
46+ assertFunctionNames : [ 'expect*' , 'assert' , 'createAndValidate' ] ,
6247 } ,
6348 ] ,
6449 } ,
6550 } ,
51+ {
52+ // Templates lack installed dependencies, and test fixtures can expect type errors.
53+ files : [
54+ 'packages/create-rslib/template-*/**' ,
55+ 'tests/integration/**/{__fixtures__,src}/**' ,
56+ 'tests/e2e/**/src/**' ,
57+ ] ,
58+ languageOptions : {
59+ parserOptions : {
60+ projectService : false ,
61+ } ,
62+ } ,
63+ } ,
6664] ) ;
6765
6866define . fmt ( {
0 commit comments