Skip to content

[FEATURE] buildRouteInfoMetadata#275

Merged
chadhietala merged 2 commits intomasterfrom
impl-build-routeinfo-metadata
Dec 7, 2018
Merged

[FEATURE] buildRouteInfoMetadata#275
chadhietala merged 2 commits intomasterfrom
impl-build-routeinfo-metadata

Conversation

@chadhietala
Copy link
Contributor

This is the router.js work required for emberjs/rfcs#398

let { name, params, paramNames, context, route } = info;
if (ROUTE_INFOS.has(info) && includeAttributes) {
let routeInfo = ROUTE_INFOS.get(info)!;
routeInfo = attachMetadata(route!, routeInfo);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why do we need to assert route is non-null here? Is it guaranteed to be populated by this phase of the lifecycle?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, it is in a resolved state. This function is also used for the pre-resolved state.

@chadhietala chadhietala merged commit 51a3c9c into master Dec 7, 2018
@chadhietala chadhietala deleted the impl-build-routeinfo-metadata branch December 7, 2018 16:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants