@tsparticles/slim
Version:
Slim tsParticles bundle — core engine with essential plugins, presets, and interactions for lightweight particle animations. Ready to use components available for React, Vue.js (2.x and 3.x), Angular, Svelte, jQuery, Preact, Riot.js, Inferno.
70 lines (69 loc) • 4.48 kB
JavaScript
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.loadSlim = loadSlim;
const basic_1 = require("@tsparticles/basic");
const plugin_easing_quad_1 = require("@tsparticles/plugin-easing-quad");
const shape_emoji_1 = require("@tsparticles/shape-emoji");
const interaction_external_attract_1 = require("@tsparticles/interaction-external-attract");
const interaction_external_bounce_1 = require("@tsparticles/interaction-external-bounce");
const interaction_external_bubble_1 = require("@tsparticles/interaction-external-bubble");
const interaction_external_connect_1 = require("@tsparticles/interaction-external-connect");
const interaction_external_destroy_1 = require("@tsparticles/interaction-external-destroy");
const interaction_external_grab_1 = require("@tsparticles/interaction-external-grab");
const interaction_external_parallax_1 = require("@tsparticles/interaction-external-parallax");
const interaction_external_pause_1 = require("@tsparticles/interaction-external-pause");
const interaction_external_push_1 = require("@tsparticles/interaction-external-push");
const interaction_external_remove_1 = require("@tsparticles/interaction-external-remove");
const interaction_external_repulse_1 = require("@tsparticles/interaction-external-repulse");
const interaction_external_slow_1 = require("@tsparticles/interaction-external-slow");
const shape_image_1 = require("@tsparticles/shape-image");
const plugin_interactivity_1 = require("@tsparticles/plugin-interactivity");
const updater_life_1 = require("@tsparticles/updater-life");
const shape_line_1 = require("@tsparticles/shape-line");
const updater_paint_1 = require("@tsparticles/updater-paint");
const interaction_particles_attract_1 = require("@tsparticles/interaction-particles-attract");
const interaction_particles_collisions_1 = require("@tsparticles/interaction-particles-collisions");
const interaction_particles_links_1 = require("@tsparticles/interaction-particles-links");
const shape_polygon_1 = require("@tsparticles/shape-polygon");
const updater_rotate_1 = require("@tsparticles/updater-rotate");
const shape_square_1 = require("@tsparticles/shape-square");
const shape_star_1 = require("@tsparticles/shape-star");
async function loadSlim(engine) {
engine.checkVersion("4.6.0");
await engine.pluginManager.register(async (e) => {
const loadInteractivityForSlim = async (e) => {
await (0, plugin_interactivity_1.loadInteractivityPlugin)(e);
await Promise.all([
(0, interaction_external_parallax_1.loadExternalParallaxInteraction)(e),
(0, interaction_external_attract_1.loadExternalAttractInteraction)(e),
(0, interaction_external_bounce_1.loadExternalBounceInteraction)(e),
(0, interaction_external_bubble_1.loadExternalBubbleInteraction)(e),
(0, interaction_external_connect_1.loadExternalConnectInteraction)(e),
(0, interaction_external_destroy_1.loadExternalDestroyInteraction)(e),
(0, interaction_external_grab_1.loadExternalGrabInteraction)(e),
(0, interaction_external_pause_1.loadExternalPauseInteraction)(e),
(0, interaction_external_push_1.loadExternalPushInteraction)(e),
(0, interaction_external_remove_1.loadExternalRemoveInteraction)(e),
(0, interaction_external_repulse_1.loadExternalRepulseInteraction)(e),
(0, interaction_external_slow_1.loadExternalSlowInteraction)(e),
(0, interaction_particles_attract_1.loadParticlesAttractInteraction)(e),
(0, interaction_particles_collisions_1.loadParticlesCollisionsInteraction)(e),
(0, interaction_particles_links_1.loadParticlesLinksInteraction)(e),
]);
};
await Promise.all([
(0, basic_1.loadBasic)(e),
loadInteractivityForSlim(e),
(0, plugin_easing_quad_1.loadEasingQuadPlugin)(e),
(0, shape_emoji_1.loadEmojiShape)(e),
(0, shape_image_1.loadImageShape)(e),
(0, shape_line_1.loadLineShape)(e),
(0, shape_polygon_1.loadPolygonShape)(e),
(0, shape_square_1.loadSquareShape)(e),
(0, shape_star_1.loadStarShape)(e),
(0, updater_life_1.loadLifeUpdater)(e),
(0, updater_paint_1.loadPaintUpdater)(e),
(0, updater_rotate_1.loadRotateUpdater)(e),
]);
});
}