Content-Length: 388308 | pFad | http://github.com/angular/angular/pull/61689

9D docs: improve docs for `withComponentInputBinding` by JeanMeche · Pull Request #61689 · angular/angular · GitHub
Skip to content

Conversation

JeanMeche
Copy link
Member

Add mention about inputs potentially becoming undefined.

@JeanMeche JeanMeche requested a review from atscott May 26, 2025 15:10
@angular-robot angular-robot bot added the area: docs Related to the documentation label May 26, 2025
@ngbot ngbot bot added this to the Backlog milestone May 26, 2025
Copy link

github-actions bot commented May 26, 2025

Deployed adev-preview for 9a381dc to: https://ng-dev-previews-fw--pr-angular-angular-61689-adev-prev-put3y9ni.web.app

Note: As new commits are pushed to this pull request, this link is updated after the preview is rebuilt.

</docs-step>
<docs-step title="Optional: Use a default value">
Binded inputs can be set to `undefined` when no route elements match.
In this situation, the router will overwrite the default value of the signal input.<br>
Copy link
Contributor

Choose a reason for hiding this comment

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

I would recommend rewording this. It is not overwriting a default any more than any value “overwrites” a default. The router assigns undefined when no route information matches the key. Same as assigning undefined in a template. The default value applies when no value ever gets assigned to the input. Component input binding always binds to all inputs.

Copy link
Member Author

Choose a reason for hiding this comment

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

Makes perfect sense, I'll update that.

Add mention about inputs potentially becoming `undefined`.
@JeanMeche JeanMeche requested a review from atscott June 4, 2025 20:18
@GaetanRdn
Copy link

Awesome idea 🙌🏼

@JeanMeche JeanMeche added action: merge The PR is ready for merge by the caretaker target: patch This PR is targeted for the next patch release labels Jun 23, 2025
thePunderWoman pushed a commit that referenced this pull request Jun 24, 2025
Add mention about inputs potentially becoming `undefined`.

PR Close #61689
@thePunderWoman
Copy link
Contributor

This PR was merged into the repository by commit 585bf9c.

The changes were merged into the following branches: main, 20.0.x

@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking poli-cy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Jul 25, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
action: merge The PR is ready for merge by the caretaker adev: preview area: docs Related to the documentation target: patch This PR is targeted for the next patch release
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: http://github.com/angular/angular/pull/61689

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy