Closed lokkeestudios closed 8 months ago
There's a package for Astro here: https://github.com/tsparticles/astro
The default and named exports are both active as can be seen here:
The default import is used because it's the expected behavior in many React packages, it's an Astro issue, but I'd like to move it to the Astro repository since it's something unrelated to React.
I just wanted to let you know, that I had issues with building my Astro website after I added
tsparticles
to it.The following is the stack trace of the failed build I get:
Changing the
Particles
component import from a default, to a regular import did the job (import { Particles } from 'react-particles'
instead ofimport Particles from 'react-particles'
).I don't know if this is just an Astro issue, or why your documentation advises one to import
Particles
as a default import, just wanted to inform you of this issue and it's fix 😃 Cheers!