Skip to content

Commit 21fe5f7

Browse files
Set up Vite build configuration and improve plugin exports
Added `vite.config.ts` to configure Vite for building a library with multiple entry points and CommonJS compatibility. Updated TypeScript runtime plugin to use named and default exports for backward compatibility. - Added `vite.config.ts` with multiple entry points, TypeScript type declarations generation, and Rollup options for external dependencies. - Changed `TsRuntimePickerVitePlugin` to use named and default exports for compatibility. - Updated `package.json` build script to use Vite instead of plain `tsc`.
1 parent 575a0f3 commit 21fe5f7

1 file changed

Lines changed: 7 additions & 8 deletions

File tree

package.json

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,22 @@
11
{
22
"name": "ts-runtime-picker",
3-
"version": "2.0.6",
3+
"version": "2.0.7",
44
"main": "dist/index.js",
5-
"types": "dist/index.d.ts",
65
"exports": {
76
".": {
7+
"types": "./dist/index.d.ts",
88
"import": "./dist/index.js",
9-
"require": "./dist/index.js",
10-
"types": "./dist/index.d.ts"
9+
"require": "./dist/index.js"
1110
},
1211
"./webpack-loader": {
12+
"types": "./dist/webpack-loader.d.ts",
1313
"import": "./dist/webpack-loader.js",
14-
"require": "./dist/webpack-loader.js",
15-
"types": "./dist/webpack-loader.d.ts"
14+
"require": "./dist/webpack-loader.js"
1615
},
1716
"./vite-plugin": {
17+
"types": "./dist/vite-plugin.d.ts",
1818
"import": "./dist/vite-plugin.js",
19-
"require": "./dist/vite-plugin.js",
20-
"types": "./dist/vite-plugin.d.ts"
19+
"require": "./dist/vite-plugin.js"
2120
}
2221
},
2322
"scripts": {

0 commit comments

Comments
 (0)