ReferenceEffectsInterface
BaseEffectOptions
Shared options for effects.
extended by ConfettiOptions, CreateEffectOptions, SparklesOptions
Shared options for built-in and custom effects.
Properties
Section titled “Properties”canvasoptionalHTMLCanvasElementA canvas to draw onto. If none is provided, party.js draws onto a fullscreen canvas it shares between all effects, and removes it once no effect is using it anymore. If provided, positions are measured from the canvas’ top-left corner: the built-in effects measure their target relative to it, and a custom effect’s origin is given in its coordinates (see measureTarget()).
reducedMotionoptionalReducedMotionWhat the effect does when the user has asked their system for reduced motion. A skipped effect draws nothing, and the
finishedpromise on the effect handle resolves as “completed” aftercreateEffect()returns, unless you stop the effect immediately. See ReducedMotion for more information. Without this option, the default set with setDefaultReducedMotion() is used, which is"skip"unless you changed it.seedoptionalnumberA seed for the effect’s random number generator. The same seed with the same options produces the same visuals each time. Without one, a random seed is generated and every run of the effect looks different.