jSquash icon indicating copy to clipboard operation
jSquash copied to clipboard

Add worker helper or example?

Open jamsinclair opened this issue 3 years ago • 2 comments

jamsinclair avatar Nov 13 '21 04:11 jamsinclair

@jamsinclair Is there anything specific that needs to be done to run this in a worker?

marklundin avatar Oct 05 '23 14:10 marklundin

@marklundin, nope so long as you can import them and bundle the worker yourself it should be fine!

The only known issue is #37.

jamsinclair avatar Nov 09 '23 15:11 jamsinclair

I've added an example at https://github.com/jamsinclair/jSquash/blob/main/examples/web-workers to show case how you can run the code from a Web Worker.

At this time I don't want to abstract the WebWorker part and leave that to the user. For several reasons:

  • Different bundlers have different opinions on how Workers get handled and bundled
  • It may be better to do several tasks in a worker rather than just run one operation

jamsinclair avatar Jun 18 '24 04:06 jamsinclair