Skip to content

docs(router): update parameter inheritance guide for the new default - #71049

Merged
atscott merged 1 commit into
angular:mainfrom
GabeSilvaDev:docs/router-params-inheritance-default
Sep 29, 2026
Merged

atscott merged 1 commit into
angular:mainfrom
GabeSilvaDev:docs/router-params-inheritance-default

Conversation

@GabeSilvaDev

Copy link
Copy Markdown
Contributor

PR Checklist

Please check if your PR fulfills the following requirements:

PR Type

What kind of change does this PR introduce?

  • Bugfix
  • Feature
  • Code style update (formatting, local variables)
  • Refactoring (no functional changes, no api changes)
  • Build related changes
  • CI related changes
  • Documentation content changes
  • angular.dev application / infrastructure changes
  • Other... Please describe:

What is the current behavior?

Issue Number: N/A

The "Control parameter inheritance" section was updated when #68256 changed the default paramsInheritanceStrategy to 'always', but the example still leads with the 'emptyOnly' configuration and the parent route traversal.

This makes the default behavior less clear, since the first example a reader sees is for the legacy option rather than the default.

The RouteReuseStrategy table also still marks shouldDestroyInjector as "(Experimental)", even though the feature was stabilized in #70443.

What is the new behavior?

The parameter inheritance section now starts with the default 'always' behavior, showing a Customer component reading the inherited parameters directly.

The 'emptyOnly' configuration is then documented as the legacy option, along with the parent traversal example.

The "(Experimental)" label is also removed from the shouldDestroyInjector row.

Does this PR introduce a breaking change?

  • Yes
  • No

Other information

The 'emptyOnly' description matches the paramsInheritanceStrategy JSDoc in packages/router/src/router_config.ts.

The section was only partially updated when `'always'` became the default:
it still showed the `'emptyOnly'` configuration and the parent traversal
example before the explanation of the default. Show the default behavior
first and move `'emptyOnly'` to a legacy note. Also drop the
"(Experimental)" tag from `shouldDestroyInjector`, which is now stable.
@pullapprove
pullapprove Bot requested a review from atscott September 29, 2026 17:01
@angular-robot angular-robot Bot added area: docs Related to the documentation area: router labels Sep 29, 2026
@ngbot ngbot Bot added this to the Backlog milestone Sep 29, 2026
@atscott atscott added action: merge The PR is ready for merge by the caretaker target: patch This PR is targeted for the next patch release labels Sep 29, 2026
@atscott
atscott merged commit 4e17af7 into angular:main Sep 29, 2026
30 checks passed
@atscott

atscott commented Sep 29, 2026

Copy link
Copy Markdown
Contributor

This PR was merged into the repository. The changes were merged into the following branches:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

action: merge The PR is ready for merge by the caretaker area: docs Related to the documentation area: router target: patch This PR is targeted for the next patch release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants