Skip to content

Commit 284e055

Browse files
Fix types export after Vite v5 bump (#110)
fix: improve types export Signed-off-by: Edvinas Jurele <[email protected]>
1 parent 3c8478d commit 284e055

File tree

2 files changed

+3
-7
lines changed

2 files changed

+3
-7
lines changed

lib/tsconfig.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,5 +8,5 @@
88
"extends": "astro/tsconfigs/base",
99
"$schema": "https://json.schemastore.org/tsconfig",
1010
"include": ["./*.astro", "./**/*.ts"],
11-
"exclude": ["node_modules/*", "./vite*.ts", "dist"]
11+
"exclude": ["node_modules/*", "./vite*.ts", "**/*.spec.ts", "dist"]
1212
}

lib/vite.config.ts

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { defineConfig, Plugin } from "vite";
1+
import { defineConfig } from "vite";
22
import path from "path";
33
import dts from "vite-plugin-dts";
44

@@ -13,10 +13,6 @@ export default defineConfig(() => {
1313
fileName: (format) => (format === "es" ? `${name}.mjs` : `${name}.js`),
1414
},
1515
},
16-
plugins: [
17-
dts({
18-
outputDir: "dist/types",
19-
}) as unknown as Plugin,
20-
],
16+
plugins: [dts({ entryRoot: "src", outDir: "dist/types" })],
2117
};
2218
});

0 commit comments

Comments
 (0)