tsparticles / angular

Angular tsParticles official component
MIT License
31 stars 5 forks source link

Angular 17 - Particles Do Not Render #96

Open vbpradoo opened 3 months ago

vbpradoo commented 3 months ago

Details

Description:

I'm encountering an issue with particle rendering in an Angular 17 environment. Despite having no compilation errors, the particles are not being rendered on the screen. The only visible item is the background. This behavior persists even after thorough checks of the code and environment.

Steps to Reproduce:

Set up an Angular 17 project environment. Integrate particle rendering functionality. Run the application. Observe that particles are not rendered, only the background is displayed. Expected Behavior: Particles should render as expected alongside the background in the Angular 17 environment.

Environment:

Angular CLI: 17.0.10 Node: 18.17.1 Package Manager: npm 9.6.7 OS: win32 x64

Angular: 17.3.0 ... animations, cdk, common, compiler, compiler-cli, core, forms ... material, platform-browser, platform-browser-dynamic, router

Package Version

@angular-devkit/architect 0.1703.0 @angular-devkit/build-angular 17.3.0 @angular-devkit/core 17.3.0 @angular-devkit/schematics 17.0.10 @angular/cli 17.0.10 @schematics/angular 17.0.10 ng-packagr 17.3.0 rxjs 7.6.0 typescript 5.2.2 zone.js 0.14.4 Operating System: Windows Particle rendering library/version: @tsparticles/angular Additional Information: These are the libraries and versions used: "@tsparticles/angular": "^3.0.0", "@tsparticles/engine": "^3.3.0", I have created a stackblitz project that reproduces the error: StackBlitz Recreation

By the way I have tried to use the code that appears in the repository but there are 2 enums that are not packed within @tsparticles/engine. These enums are ClickMode and HoverMode.

Any assistance in resolving this issue would be greatly appreciated. Thank you!

matteobruni commented 3 months ago

Please check the README file twice. You're code is missing the ngParticlesService.init call.