Neutron Polarization Manipulator
Miss any of our Open RFC calls?Watch the recordings here! »

react-hooks-use-offscreen-drawing-canvas

0.1.3 • Public • Published

Use Offscreen Drawing Canvas

This module is based on my simmilar module react-hooks-use-drawing-canvas that runs the drawing code on the main thread. When running potentially complex drawings however, the main thread will block while drawing calculation is being done.

To overcome this, we can make use of the OffscreenCanvas interface, and run the drawing method in a web-worker thread that will never block the main thread. Even while it is calculating!

Installation

yarn add react-hooks-use-offscreen-drawing-canvas

Keywords

none

Install

npm i react-hooks-use-offscreen-drawing-canvas

DownloadsWeekly Downloads

8

Version

0.1.3

License

MIT

Unpacked Size

8.85 kB

Total Files

7

Last publish

Collaborators

  • avatar