Optional ReadonlyadaptiveAdaptive Quality.
Watches the frame rate while particles animate. When frames stay slow (below about 50 fps) and konfeti's
own drawing is a real part of the cost, the quality steps down one level at a time: 1 renders at CSS
resolution, 2 also drops shadows, shine and trails, 3 also spawns 60% of the requested particles.
After a few seconds of smooth frames it steps back up.
Optional ReadonlydefaultsInstance Default Burst Options.
Merged under every fire() call on this instance (fire options win). Nested groups such as paper and
physics are merged key by key.
Optional ReadonlydisableRespect Reduced Motion.
When true and the user has prefers-reduced-motion: reduce, fire() draws nothing and its handle
resolves immediately.
Optional ReadonlyfixedFixed Time Step.
Simulate in fixed 1/60 s steps instead of the real frame time. A burst fired again with the same seed
(and the same options and canvas size) then replays exactly, particle for particle, on any display and at
any frame rate. Motion updates 60 times per second, also on faster screens.
Optional ReadonlyframeCustom Frame Scheduler.
Replaces requestAnimationFrame. Intended for tests and custom render loops.
Optional ReadonlymaxDevice Pixel Ratio Cap.
Limits canvas resolution on very dense screens to save GPU time. 1 renders at CSS resolution.
Optional ReadonlymaxMaximum Live Particles. When a new burst would exceed it, the oldest particles are removed first.
Optional ReadonlyresizeAutomatic Canvas Resize. Keeps the canvas' pixel size in sync with its CSS size (and the window, for the built-in overlay canvas). Disable if you manage the canvas size yourself.
Optional ReadonlyzOverlay Canvas z-index.
Only used by the built-in fullscreen canvas (when no canvas is passed to KonfetiFactory.create()).
Options for a Konfeti Instance.
Example