I am trying to learn NGXS and, therefore, following a tutorial. The tutorial said to install ngxs store and other dependencies, and I did with:
npm install @ngxs/store --save;
npm i @ngxs/logger-plugin --save;
npm i @ngxs/devtools-plugin --save-dev
But after doing that, my code will not work and says there is a problem with my app.module.ts:
'NgxsRootModule' does not appear to be an NgModule class. 'NgxsLoggerPluginModule' does not appear to be an NgModule class. 'NgxsReduxDevtoolsPluginModule' does not appear to be an NgModule class.
Here is my app.module.ts:
import { NgModule } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser';
import { AppRoutingModule } from './app-routing.module';
import { AppComponent } from './app.component';
import { NgxsModule } from '@ngxs/store';
import { NgxsLoggerPluginModule } from '@ngxs/logger-plugin';
import { NgxsReduxDevtoolsPluginModule } from '@ngxs/devtools-plugin';
@NgModule({
declarations: [
AppComponent
],
imports: [
BrowserModule,
AppRoutingModule,
NgxsModule.forRoot([]), NgxsLoggerPluginModule.forRoot(), NgxsReduxDevtoolsPluginModule.forRoot()
],
providers: [],
bootstrap: [AppComponent]
})
export class AppModule { }
Does anyone have any idea on how this could be solved, please? I tried a lot of things already, such as restarting VSCode and deleting node_modules and running npm i again, to no results.
Thanks in advance!