101arrowz
101arrowz
Fixed in v0.7.4.
Fixed in v0.7.4. Sorry for the long delay!
Yes, as I mentioned in the original PR, that needs to be `import { createContext } from 'isoworker'`.
No, the pure `isoworker` import works. The "exports" field enables it to automatically find "esm/browser.js", and this should function with all bundlers (Rollup, Parcel, Webpack, etc.) I have tested this...
I see, so it's an issue with the bundler config that is a bit difficult to change. In that case, does `import { createContext } from 'fflate/browser'` work? I'm guaranteeing...
BTW, consider trying this solution out: https://github.com/reactioncommerce/reaction-component-library/issues/399#issuecomment-467860022
If `useWorker` is configured to use the ESM export from `isoworker`, rather than letting the bundler decide to use the CommonJS one, it will work properly.
FWIW this cancellation functionality is offered in [`fflate`](https://github.com/101arrowz/fflate). All of the asynchronous APIs can be terminated. ```js import { zip, strToU8 } from 'fflate'; const terminate = zip({ 'ex.txt': strToU8('hello...
Just BTW, you can also import the raw JSON like you have already done (i.e. it will be loaded as a JavaScript object). ```js import test from './resources/test.json'; console.log(test); //...
Possibly fixed by #9068 - can someone please test? I encountered a variant of this issue locally and my changes in that PR fixed it.