Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
FilterTabRowComponent,
FilterInputComponent,
RightSidebarComponent,
FieldComponent,
ErrorComponent,
],
imports: [
BrowserAnimationsModule,
BrowserModule,
ClickOutsideModule,
StoreModule.forRoot(reducers, { metaReducers }),
RouterModule.forRoot(appRoutes),
StoreRouterConnectingModule.forRoot({
stateKey: 'router',
}),
StoreDevtoolsModule.instrument({ maxAge: 25 }),
EffectsModule.forRoot([ReportEffects, ConfigEffects, RouterEffects]),
HttpClientModule,
TreeModule.forRoot(),
MatSortModule,
HttpClientXsrfModule.withOptions({
cookieName: 'csrftoken',
headerName: 'X-CSRFToken',
}),
FormsModule,
...MatModules,
],
providers: [
ApiService,
{ provide: RouterStateSerializer, useClass: CustomSerializer },
{
provide: HTTP_INTERCEPTORS,
AboutDesktopComponent,
AboutMobileComponent,
RadarMobileComponent,
RadarDesktopComponent
],
imports: [
BrowserModule,
AppRoutingModule,
AngularMaterialModule,
LayoutModule,
HttpClientModule,
MatTableModule,
MatPaginatorModule,
MatSortModule,
StoreModule.forRoot(reducers, { metaReducers }),
!environment.production ? StoreDevtoolsModule.instrument() : [],
EffectsModule.forRoot([WeatherEffects]),
FormsModule,
ReactiveFormsModule
],
providers: [],
bootstrap: [AppComponent]
})
export class AppModule { }
@NgModule({
declarations: [
AppComponent,
CompanyListComponent,
CompanyTableComponent,
CompanyEditComponent
],
imports: [
BrowserModule,
FormsModule,
ReactiveFormsModule,
HttpModule,
AppRoutingModule,
StoreModule.forRoot({companies: companyReducer}),
EffectsModule.forRoot([CompanyEffects]),
StoreDevtoolsModule.instrument({maxAge: 25})
],
providers: [
CompanyService,
],
bootstrap: [AppComponent]
})
export class AppModule { }
@NgModule({
declarations: [
AppComponent
],
imports: [
BrowserModule,
FormsModule,
ReactiveFormsModule,
HttpClientModule,
AppRoutingModule,
StoreRouterConnectingModule.forRoot({
serializer: CustomSerializer
}),
StoreModule.forRoot(reducers, { metaReducers }),
EffectsModule.forRoot([]),
StoreDevtoolsModule.instrument({ maxAge: 25, logOnly: environment.production })
],
providers: [
{ provide: 'API_URL', useValue: environment.api },
{ provide: LocationStrategy, useClass: HashLocationStrategy }
],
bootstrap: [AppComponent]
})
export class AppModule { }
@NgModule({
declarations: [
AppComponent
],
imports: [
BrowserModule,
SharedModule,
FormsModule,
HttpClientModule,
StoreModule.forRoot(reducers, { metaReducers }),
EffectsModule.forRoot([
ProfileEffects,
FeedEffects,
WeatherEffects
]),
!environment.production ? StoreDevtoolsModule.instrument({ maxAge: 50 }) : [],
RouterModule.forRoot(
routes,
{
useHash: true
}
)
],
providers: [
WeatherService
],
bootstrap: [
AppComponent
]
})
export class AppModule {}
import { translationChunksConfig, translations } from '@spartacus/assets';
import { TestConfigModule } from '@spartacus/core';
import {
B2cStorefrontModule,
StorefrontComponent,
} from '@spartacus/storefront';
import { environment } from '../environments/environment';
import { TestOutletModule } from '../test-outlets/test-outlet.module';
registerLocaleData(localeDe);
registerLocaleData(localeJa);
registerLocaleData(localeZh);
const devImports = [];
if (!environment.production) {
devImports.push(StoreDevtoolsModule.instrument());
}
@NgModule({
imports: [
BrowserModule.withServerTransition({ appId: 'spartacus-app' }),
BrowserTransferStateModule,
B2cStorefrontModule.withConfig({
backend: {
occ: {
baseUrl: environment.occBaseUrl,
legacy: false,
},
oms: {
baseUrl: environment.occBaseUrl,
},
AdminModule,
AppRoutingModule,
HttpClientModule,
AngularFireModule.initializeApp(environment.firebase),
AngularFireAuthModule,
AngularFirestoreModule,
AngularFireDatabaseModule,
CoreModule,
StoreModule.forRoot(reducers, {
runtimeChecks: {
strictStateImmutability: true,
strictActionImmutability: true
},
metaReducers
}),
!environment.production ? StoreDevtoolsModule.instrument() : [],
EffectsModule.forRoot([])
],
bootstrap: [AppComponent]
})
export class AppModule {}
StoreModule.forRoot({ app: appReducer }, { initialState: INITIAL_STATE }),
StoreRouterConnectingModule.forRoot({ stateKey: 'router' }),
SharedStoreModule,
EffectsModule.forRoot([
AppEffects,
NodeEffects,
DownloadEffects,
ViewerEffects,
SearchEffects,
LibraryEffects,
UploadEffects,
FavoriteEffects,
TemplateEffects
]),
!environment.production
? StoreDevtoolsModule.instrument({ maxAge: 25 })
: []
]
})
export class AppStoreModule {}
import { environment } from '../../environments/environment';
import { TodoService } from './services';
import { RequestInterceptor } from './interceptors';
import { reducers, metaReducers } from './reducers';
import { SpinnerComponent } from './components';
/**
* Core module
*/
@NgModule({
imports: [
CommonModule,
HttpClientModule,
StoreModule.forRoot(reducers, { metaReducers }),
StoreDevtoolsModule.instrument({ logOnly: environment.production }),
EffectsModule.forRoot([]),
],
exports: [
SpinnerComponent,
],
declarations: [
SpinnerComponent,
],
schemas: [CUSTOM_ELEMENTS_SCHEMA]
})
export class CoreModule {
static forRoot(): ModuleWithProviders {
return {
ngModule: CoreModule,
providers: [
TodoService,
strictStateImmutability: false,
strictActionImmutability: false,
strictStateSerializability: false,
strictActionSerializability: false,
},
}
: {
runtimeChecks: {
strictStateImmutability: true,
strictActionImmutability: true,
strictStateSerializability: true,
strictActionSerializability: true,
},
}),
EffectsModule.forRoot([]),
!environment.production ? StoreDevtoolsModule.instrument() : [],
ReactiveFormsModule,
FormlyModule.forRoot({
extras: {
immutable: true
},
validationMessages: [
{name: 'required', message: 'This field is required'},
{name: 'pattern', message: 'Invalid input'},
],
}),
ServiceWorkerModule.register('ngsw-worker.js', {enabled: environment.production}),
TranslateModule.forRoot({
loader: {
provide: TranslateLoader,
useFactory: createTranslateLoader,
deps: [HttpClient]