MCPcopy
hub / github.com/rx-angular/rx-angular / IsrService

Class IsrService

libs/isr/browser/src/isr.service.ts:7–42  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

5
6@Injectable({ providedIn: 'root' })
7export class IsrService implements IsrServiceInterface {
8 private platformId = inject(PLATFORM_ID);
9
10 constructor() {
11 if (isPlatformServer(this.platformId)) {
12 throw new Error(
13 `IsrService should not be instantiated on the server.
14 It is only used on the client as a injection token.`,
15 );
16 }
17 }
18
19 getState(): IsrState {
20 return { revalidate: null, errors: [], extra: {} };
21 }
22
23 patchState(partialState: Partial<IsrState>): void {
24 return;
25 }
26
27 getExtra(): Record<string, unknown> {
28 return {};
29 }
30
31 activate(): void {
32 return;
33 }
34
35 addError(error: Error): void {
36 return;
37 }
38
39 addExtra(extra?: Record<string, unknown> | undefined): void {
40 return;
41 }
42}

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected