Magnetic
VERSION2.3.0
LICENSEMIT
CONFIG2 Options
Attracts the cursor to interactive elements using physics-based magnetism.
Installation
pnpm add @supermousejs/magneticUsage
app.use(Magnetic({ attraction: 0.4, distance: 100 }));Configuration
* Reactive Property| Option | Type | Default | Description |
|---|---|---|---|
| attraction * | number | 0.3 | Strength of the pull (0-1). |
| distance * | number | 100 | Radius in pixels where attraction begins. |