[Bug] ESM doesn't work without "type": "module" in node
JamesAPetts opened this issue · 1 comments
JamesAPetts commented
Bug description
Running vtk.js on the backend doesn't work without modifying the package.json.
(Maybe this is a feature request?)
Steps to reproduce
Try installing @kitware/vtk.js on node when using ESM. The package is incorrectly loaded, and it will run properly when "type": "module" is added.
Detailed Behavior
No response
Expected Behavior
It works OOTB in node. Is there any other issue that would be caused by adding "type": "module" to the package.json?
Environment
- vtk.js version: master
- node.js 18+ (but probably before also).
daker commented
What's the purpose of running it on the backend?