Skip to content

Commit 4801659

Browse files
committed
Remove unused dependency
1 parent d66e629 commit 4801659

2 files changed

Lines changed: 4 additions & 1 deletion

File tree

‎package.json‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,6 @@
133133
"@types/node": "^26.6.11",
134134
"assert": "^2.1.0",
135135
"buffer": "^6.0.3",
136-
"canvas": "^3.2.3",
137136
"check-node-version": "^4.2.1",
138137
"deep-equal": "^2.2.3",
139138
"esbuild": "^0.28.2",

‎tasks/util/plotly_node.mjs‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
import fs from 'fs';
22
import { JSDOM } from 'jsdom';
33

4+
// When plotly loads, some of its WebGL text dependencies call `canvas.getContext('2d')`.
5+
// jsdom has no canvas backend without the optional `@napi-rs/canvas` package, so `getContext` returns null.
6+
// For each call, jsdom then prints "Not implemented: HTMLCanvasElement's getContext() method".
7+
// These scripts never draw, so the message is harmless.
48
var window = new JSDOM('', {
59
runScripts: 'dangerously'
610
}).window;

0 commit comments

Comments
 (0)