Co-authored-by: Cursor Agent <cursoragent@cursor.com> Co-authored-by: fisker Cheung <lionkay@gmail.com> Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
46 lines
850 B
HTML
46 lines
850 B
HTML
@boundary {
|
|
<app-risky-component />
|
|
} @error (let err; retry
|
|
|
|
= $reset; when
|
|
isNetworkError(err)) {
|
|
<app-network-error [error]="err" />
|
|
<button (click)="retry()">Retry</button>
|
|
} @error {
|
|
<app-generic-error />
|
|
}
|
|
|
|
@boundary {
|
|
<app-chart-dashboard />
|
|
} @error (let
|
|
err; reset
|
|
=
|
|
$reset; when
|
|
isRenderError(err)) {
|
|
<p>Network issue. Check your connection.</p>
|
|
<button (click)="reset()">Retry</button>
|
|
} @error {
|
|
<p>An unexpected error occurred: {{$error.message}}</p>
|
|
}
|
|
|
|
@boundary {
|
|
<complex-chart [data]="data"/>
|
|
} @error (let err=$error; let r=$reset) {
|
|
<p>Failed to load chart: {{err.message}}</p>
|
|
<button (click)="r()">Retry</button>
|
|
}
|
|
|
|
@boundary {
|
|
Main
|
|
} @error (let err; when err.message === '404') {
|
|
Not Found
|
|
}
|
|
|
|
@boundary {
|
|
Main
|
|
} @error (err = $error, retry
|
|
=
|
|
$reset) {
|
|
<button (click)="retry()">Retry</button>
|
|
}
|