Skip to content

Commit 3b9c192

Browse files
committed
Cleanup tsconfig and types for build
1 parent 70d536f commit 3b9c192

File tree

4 files changed

+53
-59
lines changed

4 files changed

+53
-59
lines changed

packages/python/plotly/js/package-lock.json

Lines changed: 41 additions & 42 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,17 @@
11
{
22
"scripts": {
3-
"build": "esbuild --bundle --format=esm --outfile=../plotly/bundle.js widget.ts",
4-
"watch": "npm run build -- --watch",
5-
"check": "tsc --noEmit"
6-
},
7-
"devDependencies": {
8-
"@types/plotly.js": "^2.33.4",
9-
"esbuild": "^0.23.1",
10-
"typescript": "^5.6.2"
3+
"build": "esbuild --bundle --alias:plotly.js=plotly.js/dist/plotly --format=esm --minify --outfile=../plotly/bundle.js widget.ts",
4+
"watch": "npm run build -- --watch --sourcemap=inline",
5+
"typecheck": "tsc --noEmit"
116
},
127
"dependencies": {
138
"@jupyter-widgets/base": "^6.0.10",
149
"lodash": "^4.17.21",
1510
"plotly.js": "^2.35.2"
11+
},
12+
"devDependencies": {
13+
"@types/plotly.js": "^2.33.4",
14+
"esbuild": "^0.23.1",
15+
"typescript": "^5.6.2"
1616
}
1717
}
Lines changed: 3 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,11 @@
11
{
22
"compilerOptions": {
3-
"declaration": true,
4-
"esModuleInterop":true,
3+
"target": "es2020",
4+
"esModuleInterop": true,
55
"lib": ["es2015", "dom"],
66
"module": "esnext",
77
"moduleResolution": "node",
8-
"noEmitOnError": true,
98
"noUnusedLocals": true,
10-
"resolveJsonModule": true,
11-
"skipLibCheck": true,
12-
"strictPropertyInitialization": false,
13-
"target": "es2015",
14-
"types": []
9+
"skipLibCheck": true
1510
}
1611
}

packages/python/plotly/js/widget.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import type { DOMWidgetModel } from "@jupyter-widgets/base";
22
import _ from "lodash";
3-
import Plotly from "plotly.js/dist/plotly";
3+
import Plotly from "plotly.js";
44

55
// @ts-ignore
66
window.PlotlyConfig = { MathJaxConfig: "local" };

0 commit comments

Comments
 (0)