TechStark / opencv-js

OpenCV JavaScript version for node.js or browser
https://npmjs.com/@techstark/opencv-js
Apache License 2.0
408 stars 36 forks source link

Does this support tree-shake? #41

Open pandafeeeder opened 11 months ago

ttt43ttt commented 11 months ago

Isn't tree-shaking a function provided by the bundler tool (e.g. webpack)?

neodescis commented 10 months ago

Isn't tree-shaking a function provided by the bundler tool (e.g. webpack)?

Yes and no. The bundler does the shaking, but a library must be shakable. There's quite a bit that goes into that! However, given that the bulk of this library is a web assembly module, I'm guessing there's not much that can be done.