Skip to content

Commit c46b154

Browse files
authored
Merge pull request #4399 from GordonSmith/SOURCE_MAPS
fix: Sourcemaps out of sync
2 parents e91cd0d + cf240dc commit c46b154

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

48 files changed

+828
-1795
lines changed

demos/gallery/vite.config.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,8 @@ export default defineConfig({
2828
minifyIdentifiers: false
2929
},
3030
plugins: [
31-
cssInjectedByJsPlugin()
31+
cssInjectedByJsPlugin({
32+
topExecutionPriority: false
33+
})
3234
],
3335
});

package-lock.json

Lines changed: 628 additions & 998 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,8 @@
3636
"devDependencies": {
3737
"@typescript-eslint/eslint-plugin": "8.29.0",
3838
"@typescript-eslint/parser": "8.29.0",
39-
"@vitest/browser": "3.1.1",
40-
"@vitest/coverage-v8": "3.1.1",
39+
"@vitest/browser": "3.2.4",
40+
"@vitest/coverage-v8": "3.2.4",
4141
"eslint": "9.24.0",
4242
"eslint-plugin-react-hooks": "5.2.0",
4343
"lerna": "8.2.1",
@@ -46,12 +46,8 @@
4646
"rimraf": "5.0.10",
4747
"typescript": "5.8.3",
4848
"typescript-eslint": "8.29.0",
49-
"vite": "6.2.5",
50-
"vite-plugin-css-injected-by-js": "3.5.2",
51-
"vite-plugin-static-copy": "2.3.0",
52-
"vite-plugin-inspect": "10.3.0",
5349
"vitepress": "1.6.3",
54-
"vitest": "3.1.1"
50+
"vitest": "3.2.4"
5551
},
5652
"overrides": {
5753
"d3-color": "3.1.0",

packages/api/src/Tooltip.ts

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -127,7 +127,6 @@ export function tip() {
127127
// v - value of the attribute
128128
//
129129
// Returns tip or attribute value
130-
// eslint-disable-next-line no-unused-vars
131130
tip.attr = function (n, v) {
132131
if (arguments.length < 2 && typeof n === "string") {
133132
return getNodeEl().attr(n);
@@ -144,8 +143,7 @@ export function tip() {
144143
// n - name of the property
145144
// v - value of the property
146145
//
147-
// Returns tip or style property value
148-
// eslint-disable-next-line no-unused-vars
146+
// Returns tip or style property value
149147
tip.style = function (n, v) {
150148
if (arguments.length < 2 && typeof n === "string") {
151149
return getNodeEl().style(n);

packages/api/vite.config.ts

Lines changed: 2 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -1,33 +1,4 @@
1-
import { defineConfig } from "vite";
2-
import { resolve } from "path";
3-
import cssInjectedByJsPlugin from "vite-plugin-css-injected-by-js";
4-
import { hpccBundleNames } from "@hpcc-js/esbuild-plugins";
1+
import { createHpccViteConfig } from "@hpcc-js/esbuild-plugins";
52
import pkg from "./package.json" with { type: "json" };
63

7-
const { alias, external, globals } = hpccBundleNames(pkg);
8-
9-
export default defineConfig({
10-
build: {
11-
lib: {
12-
entry: resolve(__dirname, "src/index.ts"),
13-
name: pkg.name,
14-
fileName: "index",
15-
},
16-
rollupOptions: {
17-
external,
18-
output: {
19-
globals,
20-
},
21-
},
22-
sourcemap: true
23-
},
24-
resolve: {
25-
alias
26-
},
27-
esbuild: {
28-
minifyIdentifiers: false
29-
},
30-
plugins: [
31-
cssInjectedByJsPlugin()
32-
],
33-
});
4+
export default createHpccViteConfig(pkg);

packages/chart/tests/chart.browser.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import { Class, HTMLWidget, SVGWidget } from "@hpcc-js/common";
44
import { describe, it, expect } from "vitest";
55
import { classDef, renderMedium, renderShort, renderSmall, renderWide } from "../../common/tests/index.ts";
66

7-
const urlSearch: string = window.location.href.split("?")[1];
7+
const urlSearch: string = "";
88
const simple = {
99
ND: {
1010
columns: ["Subject", "Year 1", "Year 2", "Year 3", "Year 4"],

packages/chart/vite.config.ts

Lines changed: 2 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -1,33 +1,4 @@
1-
import { defineConfig } from "vite";
2-
import { resolve } from "path";
3-
import cssInjectedByJsPlugin from "vite-plugin-css-injected-by-js";
4-
import { hpccBundleNames } from "@hpcc-js/esbuild-plugins";
1+
import { createHpccViteConfig } from "@hpcc-js/esbuild-plugins";
52
import pkg from "./package.json" with { type: "json" };
63

7-
const { alias, external, globals } = hpccBundleNames(pkg);
8-
9-
export default defineConfig({
10-
build: {
11-
lib: {
12-
entry: resolve(__dirname, "src/index.ts"),
13-
name: pkg.name,
14-
fileName: "index",
15-
},
16-
rollupOptions: {
17-
external,
18-
output: {
19-
globals,
20-
},
21-
},
22-
sourcemap: true
23-
},
24-
resolve: {
25-
alias
26-
},
27-
esbuild: {
28-
minifyIdentifiers: false
29-
},
30-
plugins: [
31-
cssInjectedByJsPlugin()
32-
],
33-
});
4+
export default createHpccViteConfig(pkg);

packages/codemirror/tests/codemirror.browser.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ import { Class, HTMLWidget, SVGWidget } from "@hpcc-js/common";
44
import { describe, it, expect } from "vitest";
55
import { classDef, renderMedium } from "../../common/tests/index.ts";
66

7-
const urlSearch: string = window.location.href.split("?")[1];
7+
const urlSearch: string = "";
88

99
describe("@hpcc-js/codemirror", () => {
1010
for (const key in codemirror) {

packages/codemirror/vite.config.ts

Lines changed: 2 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -1,33 +1,4 @@
1-
import { defineConfig } from "vite";
2-
import { resolve } from "path";
3-
import cssInjectedByJsPlugin from "vite-plugin-css-injected-by-js";
4-
import { hpccBundleNames } from "@hpcc-js/esbuild-plugins";
1+
import { createHpccViteConfig } from "@hpcc-js/esbuild-plugins";
52
import pkg from "./package.json" with { type: "json" };
63

7-
const { alias, external, globals } = hpccBundleNames(pkg);
8-
9-
export default defineConfig({
10-
build: {
11-
lib: {
12-
entry: resolve(__dirname, "src/index.ts"),
13-
name: pkg.name,
14-
fileName: "index",
15-
},
16-
rollupOptions: {
17-
external,
18-
output: {
19-
globals,
20-
},
21-
},
22-
sourcemap: true
23-
},
24-
resolve: {
25-
alias
26-
},
27-
esbuild: {
28-
minifyIdentifiers: false
29-
},
30-
plugins: [
31-
cssInjectedByJsPlugin()
32-
],
33-
});
4+
export default createHpccViteConfig(pkg);

packages/common/tests/common.browser.spec.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import { Button, CanvasWidget, Class, Entity, EntityCard, EntityPin, EntityRect,
33
import { describe, it, expect } from "vitest";
44
import { classDef, renderIcon, renderMedium, renderSmall } from "./index.ts";
55

6-
const urlSearch: string = window.location.href.split("?")[1];
6+
const urlSearch: string = "";
77
const menuList = ["List item 1", "This is Item 2", "List item 3", "This is list item 4", "And finally 5"];
88

99
describe("Widget.classed", () => {

0 commit comments

Comments
 (0)