3 ms·
I'd like to see a github repo. You can hit me up on twitter, info in my profile. I think even just finding the right library to make using webworkers + npm + we
by nwienert 12y ago
I'd like to see a github repo. You can hit me up on twitter, info in my profile. I think even just finding the right library to make using webworkers + npm + webpack would be great to start, because honestly its all the other stuff that slows down the thread. React can run on the main thread for the most part.
Some reading:
https://news.ycombinator.com/item?id=6982485 https://news.ycombinator.com/item?id=6982485
http://stackoverflow.com/questions/18056922/is-there-a-way-to-create-out-of-dom-elements-in-web-worker http://stackoverflow.com/questions/18056922/is-there-a-way-t...
Edit: webpack + webwoker:
https://github.com/webpack/webpack/tree/master/examples/web-worker https://github.com/webpack/webpack/tree/master/examples/web-...
- azakai 12y agoCool, I set up a repo and started a wiki on it, https://github.com/kripken/worker-ui/wiki https://github.com/kripken/worker-ui/wiki Not familiar with webpack, will take a look.
- peterhunt 12y agoIf you're interested in doing it with React, here's a video explaining how to do a custom backend: https://www.youtube.com/watch?v=eNC0mRYGWgc https://www.youtube.com/watch?v=eNC0mRYGWgc You basically need to change BackendIDOperations and ReactEventListener to send/receive messages vs talking to the real APIs. It's already set up in the codebase to do this (because it actually worked at one time). Webpack, per usual, already thought of this and has an answer for you :) https://github.com/webpack/worker-loader https://github.com/webpack/worker-loader