Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
{ name: 'vue', func: xml }
];
}
const StoreDebugModule = [
NgxsModule.forRoot([UiState, CodeGenState], {
/**
* WARNING: dont enbale the `developmentmode` config until it's been fixed!
* ENABLING THIS, WILL THROW: TypeError: Cannot assign to read only property 'microTask' of object '[object Object]'
* See similar issue in NgRx: https://github.com/brandonroberts/ngrx-store-freeze/issues/17
*/
// developmentMode: !environment.production
}),
NgxsLoggerPluginModule.forRoot({ disabled: environment.production }),
NgxsReduxDevtoolsPluginModule.forRoot({ disabled: environment.production }),
NgxsRouterPluginModule.forRoot()
];
// AoT requires an exported function for factories
export function HttpLoaderFactory(http: HttpClient) {
return new TranslateHttpLoader(http);
}
@NgModule({
declarations: [AppComponent],
imports: [
BrowserModule,
HttpClientModule,
BrowserAnimationsModule,
StoreDebugModule,
CoreModule,
DialogsModule,
ProfilePictureModule,
SettingsModule,
UserModule,
FeatureFlagModule.forRoot(),
NotImplementedModule,
FeedbackDrawerModule,
MatBadgeModule,
NgxsModule.forRoot([AppState, BookmarksState, LastPersonsState, CommonPersonsState, SearchState, TableState], {
// TODO: Fix https://github.com/T-Systems-MMS/phonebook/issues/95 first.
// developmentMode: !environment.production
}),
NgxsStoragePluginModule.forRoot({
key: ['appstate', 'bookmarks', 'commonpersons', 'lastpersons', 'tablestate']
}),
NgxsRouterPluginModule.forRoot(),
NgxsLoggerPluginModule.forRoot({ disabled: environment.production }),
NgxsReduxDevtoolsPluginModule.forRoot({ disabled: environment.production }),
AddFilterModule,
TableModule,
ApiModule,
// Has to be included here because of https://stackoverflow.com/a/41519512/9277073
FeedbackDrawerModule,
DragDropModule,
ApiModule,
IeWarningModule,
PlatformModule,
// Pages
UserPagesModule
],
providers: [
{
@NgModule({
providers: [
CoreService,
],
exports: [
ClarityModule,
ClrFormsNextModule,
],
imports: [
CommonModule,
HttpClientModule,
// NgxPageScrollModule,
NgxsModule.forRoot([]),
NgxsFormPluginModule.forRoot(),
NgxsRouterPluginModule.forRoot(),
ClarityModule,
ClrFormsNextModule,
GraphqlModule,
AuthModule,
I18nModule,
NgxsReduxDevtoolsPluginModule.forRoot({
disabled: environment.production,
}),
NgxsStoragePluginModule.forRoot({
key: 'auth.token',
}),
]
})
export class CoreModule {
constructor(
@Optional()
},
{
provide: APP_INITIALIZER,
multi: true,
deps: [Injector],
useFactory: localeInitializer,
},
],
};
};
CoreModule.decorators = [
{ type: NgModule, args: [{
imports: [
NgxsModule.forFeature([ProfileState, SessionState, ConfigState]),
NgxsStoragePluginModule.forRoot({ key: 'SessionState' }),
NgxsRouterPluginModule.forRoot(),
CommonModule,
HttpClientModule,
FormsModule,
ReactiveFormsModule,
RouterModule,
],
declarations: [
RouterOutletComponent,
DynamicLayoutComponent,
AutofocusDirective,
EllipsisDirective,
FormSubmitDirective,
LocalizationPipe,
PermissionDirective,
VisibilityDirective,
InputEventDebounceDirective,
{
provide: APP_INITIALIZER,
multi: true,
deps: [Injector],
useFactory: localeInitializer,
},
],
};
}
}
CoreModule.decorators = [
{ type: NgModule, args: [{
imports: [
NgxsModule.forFeature([ProfileState, SessionState, ConfigState]),
NgxsStoragePluginModule.forRoot({ key: 'SessionState' }),
NgxsRouterPluginModule.forRoot(),
CommonModule,
HttpClientModule,
FormsModule,
ReactiveFormsModule,
RouterModule,
],
declarations: [
RouterOutletComponent,
DynamicLayoutComponent,
AutofocusDirective,
EllipsisDirective,
ForDirective,
FormSubmitDirective,
LocalizationPipe,
PermissionDirective,
VisibilityDirective,
beforeEach(async(() => {
TestBed.configureTestingModule({
imports: [MatTooltipModule, NgxsModule.forRoot([AppState]), NgxsRouterPluginModule.forRoot()],
declarations: [TestComponentWrapper, OrganigramNodeComponent],
providers: [{ provide: MatSnackBar, useValue: null }, WindowRef],
schemas: [NO_ERRORS_SCHEMA]
}).compileComponents();
store = TestBed.get(Store);
}));
import { AppComponent } from './app.component';
@NgModule({
imports: [
BrowserModule,
BrowserAnimationsModule,
CommonModule,
MatButtonModule,
MatToolbarModule,
MatSidenavModule,
MatExpansionModule,
MatListModule,
MatDividerModule,
MatIconModule,
NgxsModule.forRoot([]),
NgxsRouterPluginModule.forRoot(),
NgxsLoggerPluginModule.forRoot(),
NgxsReduxDevtoolsPluginModule.forRoot(),
AppRoutingModule,
],
declarations: [AppComponent],
providers: [],
bootstrap: [AppComponent],
})
export class AppModule {}
{
provide: APP_INITIALIZER,
multi: true,
deps: [Injector],
useFactory: localeInitializer,
},
],
};
}
}
CoreModule.decorators = [
{ type: NgModule, args: [{
imports: [
NgxsModule.forFeature([ProfileState, SessionState, ConfigState]),
NgxsStoragePluginModule.forRoot({ key: 'SessionState' }),
NgxsRouterPluginModule.forRoot(),
CommonModule,
HttpClientModule,
FormsModule,
ReactiveFormsModule,
RouterModule,
],
declarations: [
RouterOutletComponent,
DynamicLayoutComponent,
AutofocusDirective,
EllipsisDirective,
FormSubmitDirective,
LocalizationPipe,
PermissionDirective,
VisibilityDirective,
InputEventDebounceDirective,
import { NgxsFormPluginModule } from '@ngxs/form-plugin';
import { NgxsLoggerPluginModule } from '@ngxs/logger-plugin';
import { NgxsReduxDevtoolsPluginModule } from '@ngxs/devtools-plugin';
import { NgxsRouterPluginModule } from '@ngxs/router-plugin';
import { TodosState } from '@integration/store/todos/todos.state';
import { TodoState } from '@integration/store/todos/todo/todo.state';
import { environment as env } from '../../environments/environment';
@NgModule({
imports: [
CommonModule,
NgxsFormPluginModule.forRoot(),
NgxsLoggerPluginModule.forRoot({ logger: console, collapsed: false }),
NgxsReduxDevtoolsPluginModule.forRoot({ disabled: env.production }),
NgxsRouterPluginModule.forRoot(),
NgxsModule.forRoot([TodosState, TodoState], { developmentMode: !env.production })
],
exports: [
NgxsFormPluginModule,
NgxsLoggerPluginModule,
NgxsReduxDevtoolsPluginModule,
NgxsModule
]
})
export class NgxsStoreModule {}
beforeEach(async(() => {
TestBed.configureTestingModule({
declarations: [TestComponentWrapperWithoutDisplayText, TestComponentWrapperFullIO],
imports: [
AddFilterModule,
RouterTestingModule,
NgxsModule.forRoot([SearchState]),
NgxsRouterPluginModule.forRoot()
]
}).compileComponents();
}));