Skip to content

Commit 8997a5e

Browse files
committed
Tst
1 parent 6c10fca commit 8997a5e

File tree

3 files changed

+8
-5
lines changed

3 files changed

+8
-5
lines changed

packages/react/package.json

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
"description": "Jupyter React - React.js components 100% compatible with Jupyter.",
55
"license": "MIT",
66
"main": "lib/index.js",
7+
"types": "lib/index.d.ts",
78
"files": [
89
"lib/**/*.{css,d.ts,eot,gif,html,jpg,js,js.map,json,png,svg,woff2,ttf}",
910
"style/**/*.{css,js,eot,gif,html,jpg,json,png,svg,woff2,ttf}",
@@ -29,10 +30,10 @@
2930
"access": "public"
3031
},
3132
"scripts": {
32-
"build": "gulp resources-to-lib && tsc && cross-env BUILD_LIB=true vite build",
33+
"build": "gulp resources-to-lib && tsc --emitDeclarationOnly && cross-env BUILD_LIB=true vite build",
3334
"build:lib": "cross-env BUILD_LIB=true vite build",
34-
"build:types": "tsc",
35-
"build:prod": "gulp resources-to-lib && tsc && npm run clean && npm run build:lib",
35+
"build:types": "tsc --emitDeclarationOnly",
36+
"build:prod": "gulp resources-to-lib && tsc --emitDeclarationOnly && npm run clean && npm run build:lib",
3637
"build:tsc:watch:res": "gulp resources-to-lib-watch",
3738
"build:tsc:watch:tsc": "tsc --watch",
3839
"build:webpack": "cross-env BUILD_APP=true webpack-cli build",

packages/react/tsconfig.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,13 @@
44
"exclude": ["node_modules", "src/example"],
55
"compilerOptions": {
66
"forceConsistentCasingInFileNames": true,
7-
"baseUrl": "/",
7+
"baseUrl": ".",
88
"rootDir": "./src",
99
"allowJs": false,
1010
"allowSyntheticDefaultImports": true,
11-
"composite": true,
11+
"composite": false,
1212
"declaration": true,
13+
"declarationMap": true,
1314
"esModuleInterop": true,
1415
"incremental": true,
1516
"jsx": "react-jsx",

packages/react/vite.config.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,7 @@ export default defineConfig(({ mode, command }) => {
4949
},
5050
outDir: 'lib',
5151
sourcemap: true,
52+
emptyOutDir: false, // Don't clean TypeScript output
5253
rollupOptions: {
5354
external: [
5455
'react',

0 commit comments

Comments
 (0)