Skip to content

Commit bcfa7fd

Browse files
authored
chore: integrate with rsbuild-plugin-arethetypeswrong (#5812)
1 parent 7a558a3 commit bcfa7fd

File tree

5 files changed

+34
-1
lines changed

5 files changed

+34
-1
lines changed

.github/renovate.json5

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,7 +102,7 @@
102102
'style-loader',
103103
'http-proxy-middleware',
104104
// Temporary ignore
105-
"less",
105+
'less',
106106
'@biomejs/biome',
107107
],
108108
}

pnpm-lock.yaml

Lines changed: 19 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

scripts/config/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
"@rsbuild/core": "workspace:*",
77
"@rslib/core": "0.11.2",
88
"@types/node": "^22.17.1",
9+
"rsbuild-plugin-arethetypeswrong": "0.1.0",
910
"typescript": "^5.9.2"
1011
}
1112
}

scripts/config/rslib.config.ts

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
import type { Minify } from '@rsbuild/core';
22
import { defineConfig, type LibConfig } from '@rslib/core';
3+
import { pluginAreTheTypesWrong } from 'rsbuild-plugin-arethetypeswrong';
34

45
export const commonExternals: Array<string | RegExp> = [
56
'webpack',
@@ -45,4 +46,15 @@ export const dualPackage = defineConfig({
4546
externals: commonExternals,
4647
},
4748
},
49+
plugins: [
50+
pluginAreTheTypesWrong({
51+
enable: Boolean(process.env.CI),
52+
areTheTypesWrongOptions: {
53+
ignoreRules: [
54+
// The dual package always provide the ESM types.
55+
'false-esm',
56+
],
57+
},
58+
}),
59+
],
4860
});

scripts/test-helper/package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
"require": "./dist/index.cjs"
1616
}
1717
},
18+
"types": "./dist/index.d.ts",
1819
"files": [
1920
"dist"
2021
],

0 commit comments

Comments
 (0)