From fbf09e70bfb5dbd4b20ba675438ff54090ffc24a Mon Sep 17 00:00:00 2001 From: Brian Buchanan Date: Tue, 3 Jan 2023 17:07:57 +0100 Subject: [PATCH] Add documentation note about error substate routes --- docs/ember/routes-and-controllers.md | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/docs/ember/routes-and-controllers.md b/docs/ember/routes-and-controllers.md index 05807cca9..00fd7679a 100644 --- a/docs/ember/routes-and-controllers.md +++ b/docs/ember/routes-and-controllers.md @@ -34,3 +34,16 @@ export default class MyRoute extends Route { {{this.model}} {{! MyModelType }} {{@model}} {{! MyModelType }} ``` + +For `error` substate routes, the type of `{{@model}}` will not be automatically inferred. You will need to create a backing class for the route if you consume its model in the corresponding template: + +```typescript +export default class ErrorRoute extends Route { + // ... +} +``` + + +```handlebars +{{@model}} {{! Error }} +``` \ No newline at end of file