1

I feel like there is a happy median somewhere for the withComponentInputBinding option I am missing. Right now, I include it in providing my router in app.config, and any inputs I use that have initial values will be overriden with undefined when I render the component through router-outlet if I don't specify their values in any way through the route.

You'd think it'd be possible to configure it so that if an input isn't specified you just don't pass it in rather than passing undefined, but I'm not finding any way to do that. Is it even possible?

I've tried all versions of inputs for angular, including the signal input and model features, and all of their inputs are passed as undefined. If I remove withComponentInputBinding() then the initial values are used, so I have isolated it to that as the source of the issue.

1 Answer 1

2

The behavior your are observing is as designed.

Failing to set the input to undefined would mean that it would retain the value from a previous navigation state.

Sign up to request clarification or add additional context in comments.

1 Comment

Yea I guess I figured that was the case, was just hoping there was a configuration option you could set to enable different behavior, but seeing how the issue is open I guess that currently isn't the case. Thanks!

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.