Skip to content

Add field to ResourceLoaderParams to find out whether the loader is triggered for the first time #59677

Closed

Description

@manfredsteyer

Which @angular/* package(s) are relevant/related to the feature request?

No response

Description

Sometimes, it's necessary to determine whether the loader was triggered for the first time. Before 19.1.x, we could have checked param.previous.status for Idle, but now, this status is already set to loading initially.

Proposed solution

Hence, I'd like to propose another way to achieve the same, e.g., a first flag (similar to the first flag in ngOnChanges).

Alternatives considered

We could use a flag in userland. This is doable and can be hidden in a helper function wrapping the loader. However, I assume using a first flag is easier.

Activity

  1. changed the title [-]Add field to ResourceLoaderParams to find out wether the loader is triggered for the first time[/-] [+]Add field to ResourceLoaderParams to find out whether the loader is triggered for the first time[/+] on Jan 23, 2025
  2. added this to the needsTriage milestone on Jan 23, 2025
  3. JeanMeche commented on Jan 24, 2025

    @JeanMeche
    Member

    #59708 has the fix for this

  4. alxhub commented on Jan 29, 2025

    @alxhub
    Member

    Fixed by 127fc0d

  5. angular-automatic-lock-bot commented on Mar 1, 2025

    @angular-automatic-lock-bot

    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 policy.

    This action has been performed automatically by a bot.

  6. locked and limited conversation to collaborators on Mar 1, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions