Skip to content

Console errors when required input is used in afterRenderEffect #697

Open
@Tlepel

Description

@Tlepel

Is this a regression?

No

Description

When a component uses a required input within a afterRenderEffect, Angular (error)logs the following error:

ERROR RuntimeError: NG0950: Input is required but no value is available yet. Find more at https://angular.dev/errors/NG0950

Changing the afterRenderEffect to a 'regular' effect removes the error log.

The test still passes as expected, so it's not a breaking bug.

Please provide a link to a minimal reproduction of the bug

No response

Please provide the exception or error you saw

ERROR RuntimeError: NG0950: Input is required but no value is available yet. Find more at https://angular.dev/errors/NG0950

Please provide the environment you discovered this bug in

Angular: 19.0.7
Spectator: 19.3.0
Jest: 29.7.0

Anything else?

No response

Do you want to create a pull request?

Yes

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions