turuslan / HackTimer

MIT License
491 stars 93 forks source link

Help implement HackTimer using SharedWorker #15

Closed ravelapraveen closed 8 years ago

ravelapraveen commented 8 years ago

When you open more tabs (Like 10 .. 20 or more), with each tab opening a new worker to implement HackTimer, there is an impact on system performance.

Is it possible to utilize SharedWorker to implement HackTimer?

We hope this will help achieve the same functionality across all the tabs using a single shared worker. If possible can you please suggest the changes required?

Can you share your thoughts?

turuslan commented 8 years ago

Yes it's possible to use SharedWorker.

It looks easy to implement - just add code to route requests from different tabs to worker and store tab timers data associated with tab.

But I suppose there may be some issues:

But those issues can be avoided by adapting code for specific application.