https://github.com/cmdcolin/cra-webpack5-web-worker-example
https://github.com/cmdcolin/cra-webpack5-web-worker-example
Last synced: 12 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/cmdcolin/cra-webpack5-web-worker-example
- Owner: cmdcolin
- Created: 2022-01-14T04:31:38.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2024-02-13T20:14:03.000Z (over 2 years ago)
- Last Synced: 2025-06-05T12:08:26.903Z (about 1 year ago)
- Language: TypeScript
- Homepage: https://cmdcolin.github.io/cra-webpack5-web-worker-example/
- Size: 977 KB
- Stars: 2
- Watchers: 2
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
## Using web workers with webpack 5/create-react-app v5
Follows https://webpack.js.org/guides/web-workers/
Note: jest tests do not work with syntax like import.meta.url, so this creates
a module mock to only call worker methods on the main thread of jest (e.g.
there is no actual worker in jest tests). See version v0.0.1 for simpler
code without any jest ability
## Demo
https://cmdcolin.github.io/cra-webpack5-web-worker-example