Skip to content
This repository was archived by the owner on Sep 20, 2023. It is now read-only.

Commit 7cc9f7b

Browse files
committed
Creates Base-Components-Page with lazy-loading. (#358)
1 parent 428be30 commit 7cc9f7b

7 files changed

+67
-0
lines changed

src/app/app-routing.module.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ const routes: Routes = [
55
{path: '', loadChildren: () => import('./control-center/control-center.module').then(m => m.ControlCenterModule)},
66
{path: 'desktop', loadChildren: () => import('./desktop/desktop.module').then(m => m.DesktopModule)},
77
{path: '', loadChildren: () => import('./account/account.module').then(m => m.AccountModule)},
8+
{ path: 'design', loadChildren: () => import('./base-components/base-components.module').then(m => m.BaseComponentsModule) },
89
{path: '**', redirectTo: '/'}
910
];
1011

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
import { NgModule } from '@angular/core';
2+
import { RouterModule, Routes } from '@angular/router';
3+
import { BaseComponentsComponent } from './base-components.component';
4+
5+
const routes: Routes = [{ path: '', component: BaseComponentsComponent }];
6+
7+
@NgModule({
8+
imports: [RouterModule.forChild(routes)],
9+
exports: [RouterModule]
10+
})
11+
export class BaseComponentsRoutingModule { }
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
<p>base-components works!</p>

src/app/base-components/base-components.component.scss

Whitespace-only changes.
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
import { ComponentFixture, TestBed } from '@angular/core/testing';
2+
3+
import { BaseComponentsComponent } from './base-components.component';
4+
5+
describe('BaseComponentsComponent', () => {
6+
let component: BaseComponentsComponent;
7+
let fixture: ComponentFixture<BaseComponentsComponent>;
8+
9+
beforeEach(async () => {
10+
await TestBed.configureTestingModule({
11+
declarations: [ BaseComponentsComponent ]
12+
})
13+
.compileComponents();
14+
});
15+
16+
beforeEach(() => {
17+
fixture = TestBed.createComponent(BaseComponentsComponent);
18+
component = fixture.componentInstance;
19+
fixture.detectChanges();
20+
});
21+
22+
it('should create', () => {
23+
expect(component).toBeTruthy();
24+
});
25+
});
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
import { Component } from '@angular/core';
2+
3+
@Component({
4+
selector: 'app-base-components',
5+
templateUrl: './base-components.component.html',
6+
styleUrls: ['./base-components.component.scss']
7+
})
8+
export class BaseComponentsComponent {
9+
10+
constructor() { }
11+
12+
}
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
import { NgModule } from '@angular/core';
2+
import { CommonModule } from '@angular/common';
3+
4+
import { BaseComponentsRoutingModule } from './base-components-routing.module';
5+
import { BaseComponentsComponent } from './base-components.component';
6+
7+
8+
@NgModule({
9+
declarations: [
10+
BaseComponentsComponent
11+
],
12+
imports: [
13+
CommonModule,
14+
BaseComponentsRoutingModule
15+
]
16+
})
17+
export class BaseComponentsModule { }

0 commit comments

Comments
 (0)