<ErrorView> ComponentA component used to display an error view, within layouts that use g-grid-container.
<ErrorView statusCode={404} />
useErrorPageAnalyticsThis component leverages a useErrorPageAnalytics hook internally, which reports the page error using window.location.track().
Note that
window.location.track()is initialized inConsentManager.
This hook is intended for use cases where the opinionated, g-grid-container-based styles of the default ErrorView component are not suited to a project.
| Name | Description |
|---|---|
statusCodenumber | Integer representing an HTTP response status code. Passing 404 will render "Not Found" vibes, passing any other error code will render generic error vibes. |
statusCode={404}
<ErrorView statusCode={404} />
Fallback (for 500 pages, and any non-404 statusCode)
<ErrorView statusCode={500} />