### Install masoneffect Package Source: https://masoneffect.com/labs Instructions for installing the masoneffect library using npm, yarn, or pnpm. This is the first step to using the library in your project. ```bash npm install masoneffect ``` -------------------------------- ### Initialize TextToParticle with Vanilla JavaScript Source: https://masoneffect.com/labs This snippet shows how to initialize the TextToParticle effect in a web page using vanilla JavaScript. It includes loading the library via CDN, creating an instance, and demonstrating basic functionalities like morphing text and scattering particles. The effect is attached to a specified container element. ```html
``` -------------------------------- ### Integrate TextToParticle with React Source: https://masoneffect.com/labs This snippet demonstrates how to use the TextToParticle component within a React application. It utilizes `useRef` to interact with the component's methods for morphing text, scattering particles, and updating options. It also shows how to pass initial properties and handle the `onReady` callback. ```javascript import React, { useRef } from 'react'; import TextToParticle from 'masoneffect/react/textToParticle'; import type { TextToParticleRef } from 'masoneffect/react/textToParticle'; function App() { const effectRef = useRef