Skip to content

Commit b4191f0

Browse files
authored
feat: upgrade to Angular 21 (#556)
1 parent 596d06f commit b4191f0

File tree

115 files changed

+2641
-3840
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

115 files changed

+2641
-3840
lines changed

.eslintrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
"ecmaVersion": 2018,
55
"sourceType": "module"
66
},
7-
"plugins": ["prefer-arrow"],
7+
"plugins": [],
88
"extends": ["plugin:@typescript-eslint/recommended"],
99
"rules": {
1010
"semi": ["error", "always"],

.github/workflows/single-spa-angular.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,6 @@ jobs:
3434
- name: Run ESLint
3535
run: yarn lint
3636

37-
- name: Run Jest
38-
run: yarn test:ci
39-
4037
- name: Build packages
4138
run: yarn build
4239

@@ -47,3 +44,6 @@ jobs:
4744
env:
4845
NO_UPDATE_CHECK: 1
4946
run: yarn test:ci:integration
47+
48+
- name: Run Jest
49+
run: yarn test:ci

apps/chat/src/app/app-routing.module.ts

Lines changed: 0 additions & 14 deletions
This file was deleted.

apps/chat/src/app/app.component.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@ <h1 class="title is-1">This is /chat page!</h1>
22

33
<button class="button" (click)="goToChatGroups()">Go to /chat/groups</button>
44

5-
<router-outlet></router-outlet>
5+
<router-outlet />

apps/chat/src/app/app.component.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
import { Component, ChangeDetectionStrategy } from '@angular/core';
2-
import { Router } from '@angular/router';
2+
import { Router, RouterOutlet } from '@angular/router';
33

44
@Component({
55
selector: 'chat-root',
66
templateUrl: './app.component.html',
77
changeDetection: ChangeDetectionStrategy.OnPush,
8-
standalone: false,
8+
imports: [RouterOutlet],
99
})
1010
export class AppComponent {
1111
constructor(private router: Router) {}

apps/chat/src/app/app.config.ts

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
import { APP_BASE_HREF } from '@angular/common';
2+
import type { ApplicationConfig } from '@angular/core';
3+
import { provideRouter } from '@angular/router';
4+
5+
import { routes } from './app.routes';
6+
7+
export const appConfig: ApplicationConfig = {
8+
providers: [{ provide: APP_BASE_HREF, useValue: '/chat' }, provideRouter(routes)],
9+
};

apps/chat/src/app/app.module.ts

Lines changed: 0 additions & 15 deletions
This file was deleted.

apps/chat/src/app/app.routes.ts

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
import type { Routes } from '@angular/router';
2+
3+
export const routes: Routes = [
4+
{
5+
path: 'groups',
6+
loadComponent: () => import('./pages/groups/groups.component').then(m => m.GroupsComponent),
7+
},
8+
{
9+
path: 'rooms',
10+
loadComponent: () => import('./pages/rooms/rooms.component').then(m => m.RoomsComponent),
11+
},
12+
];

apps/chat/src/app/pages/groups/groups-routing.module.ts

Lines changed: 0 additions & 12 deletions
This file was deleted.

apps/chat/src/app/pages/groups/groups.component.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ import { Router } from '@angular/router';
55
selector: 'chat-groups',
66
templateUrl: './groups.component.html',
77
changeDetection: ChangeDetectionStrategy.OnPush,
8-
standalone: false,
98
})
109
export class GroupsComponent {
1110
constructor(private router: Router) {}

0 commit comments

Comments
 (0)