Skip to content

Latest commit

 

History

History
24 lines (15 loc) · 737 Bytes

README.md

File metadata and controls

24 lines (15 loc) · 737 Bytes

pixi-webworker-example

Simple example how to implement @pixi/webworker using PixiJS 7+ using HTMLCanvasElement's transferControlToOffscreen.

View demo

Advantages

  • Render in another thread is fast and doesn't block the main thread
  • Ideal for running React or another virtual DOM-based frameworks

Disadvantages

  • Only browsers that support OffscreenCanvas
  • No interactivity (mouse, pointer or touch events)

Getting Started

Install dependencies and start. This will open in a browser.

npm install
npm start