preact-worker-demo icon indicating copy to clipboard operation
preact-worker-demo copied to clipboard

How to redo this with Comlink?

Open sdykae opened this issue 4 years ago • 1 comments

Since comlink achive to do the same with redux in a friendly way. I want to do the same with the preact dom, How can I achive this ;c. I'm unable to understand the requirements for this. Can you guide me with the very basic?

Do I need undom?

sdykae avatar Dec 29 '19 06:12 sdykae

You need to chose pretty much the same approach as in this repo. Preact uses a subset of the DOM-API which needs to be mocked inside your worker. These mocks will need to pass a message to the main thread and the main thread will need something that responds to those messages and apply it to the DOM.

marvinhagemeister avatar Jan 02 '20 08:01 marvinhagemeister