Skip to content

Commit 3ee005c

Browse files
committed
Ensure invalid types fail the build
1 parent f0fb9ce commit 3ee005c

1 file changed

Lines changed: 6 additions & 1 deletion

File tree

vite.config.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,12 @@ export default defineConfig({
2727
plugins: [
2828
dts({
2929
insertTypesEntry: true,
30-
include: ['src/**/*.ts']
30+
include: ['src/**/*.ts'],
31+
afterDiagnostic: diagnostics => {
32+
if (diagnostics.length > 0) {
33+
throw new Error("dts failed");
34+
}
35+
}
3136
})
3237
]
3338
});

0 commit comments

Comments
 (0)