cockpit-project / cockpit-machines

Cockpit UI for virtual machines
GNU Lesser General Public License v2.1
257 stars 67 forks source link

xterm.js is bundled twice in node_modules #1683

Open jelly opened 2 weeks ago

jelly commented 2 weeks ago

Use esbuild's bundle analyzer to analyse the bundle information created with ./build.js --metafile meta.json and analyse it here https://esbuild.github.io/analyze/

The import path xterm resolves to multiple files in the bundle:
    [node_modules/@patternfly/react-console/node_modules/xterm/lib/xterm.js](javascript:void 0)
    [node_modules/xterm/lib/xterm.js](javascript:void 0)
jelly commented 2 weeks ago
[jelle@t14s][~/projects/cockpit-machines]%npm ls xterm
machines@ /home/jelle/projects/cockpit-machines
├─┬ @patternfly/react-console@5.0.0
│ ├─┬ xterm-addon-fit@0.2.1
│ │ └── xterm@4.19.0 deduped
│ └── xterm@4.19.0
├─┬ xterm-addon-canvas@0.5.0
│ └── xterm@5.1.0 deduped
└── xterm@5.1.0

So we have two different versions