Skip to content

Several API updates for resource & friends from the RFC - #60919

Closed
alxhub wants to merge 4 commits into
angular:mainfrom
alxhub:resource-api
Closed

alxhub wants to merge 4 commits into
angular:mainfrom
alxhub:resource-api

Conversation

@alxhub

@alxhub alxhub commented Apr 18, 2025

Copy link
Copy Markdown
Member

No description provided.

@angular-robot angular-robot Bot added the area: core Issues related to the framework runtime label Apr 18, 2025
@ngbot ngbot Bot added this to the Backlog milestone Apr 18, 2025
@alxhub alxhub added the target: major This PR is targeted for the next major release label Apr 18, 2025

@mmalerba mmalerba left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

reviewed-for: public-api

@pullapprove
pullapprove Bot requested a review from atscott April 21, 2025 21:59

@thePunderWoman thePunderWoman left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM

reviewed-for: fw-general, angular-dev, public-api

@angular-robot angular-robot Bot added the area: common Issues related to APIs in the @angular/common package label Apr 22, 2025
alxhub added 4 commits April 23, 2025 09:16
Remove the code related to exposing the response of an HTTP request as a
`Resource` itself, as the final API will not go in this direction.
An outcome of the Resource RFC was that we should use string constants for
communicating the resource status instead of an enum. This commit converts
`ResourceStatus` accordingly.
As decided in the resource RFC, this commit renames the `request` option of
a resource to `params`, including the subsequent argument passed to the
loader. It also corrects the type in the process to properly allow narrowing
of the `undefined` value.

Fixes angular#58871
As decided in the Resource RFC, this commit renames `loader` in `rxResource`
to `stream`. Some logic is left in to support gradual rollout of this change
in g3.
@alxhub

alxhub commented Apr 23, 2025 •

Copy link
Copy Markdown
Member Author

Caretaker: this requires a g3 patch and g3 updates from cl/750662376.

TESTED=https://fusion2.corp.google.com/presubmit/749674791/OCL:749674791:BASE:750345722:1745407048633:fa4a8747/targets (TGP on TAP train, failures unrelated)

@alxhub alxhub added action: merge The PR is ready for merge by the caretaker merge: caretaker note Alert the caretaker performing the merge to check the PR for an out of normal action needed or note labels Apr 23, 2025
@mmalerba

Copy link
Copy Markdown
Contributor

This PR was merged into the repository by commit 4bcf183.

The changes were merged into the following branches: main

@mmalerba mmalerba closed this in b1bfb21 Apr 23, 2025
mmalerba pushed a commit that referenced this pull request Apr 23, 2025
An outcome of the Resource RFC was that we should use string constants for
communicating the resource status instead of an enum. This commit converts
`ResourceStatus` accordingly.

PR Close #60919
mmalerba pushed a commit that referenced this pull request Apr 23, 2025
As decided in the resource RFC, this commit renames the `request` option of
a resource to `params`, including the subsequent argument passed to the
loader. It also corrects the type in the process to properly allow narrowing
of the `undefined` value.

Fixes #58871

PR Close #60919
mmalerba pushed a commit that referenced this pull request Apr 23, 2025
#60919)

As decided in the Resource RFC, this commit renames `loader` in `rxResource`
to `stream`. Some logic is left in to support gradual rollout of this change
in g3.

PR Close #60919
@angular-automatic-lock-bot

Copy link
Copy Markdown

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.

@angular-automatic-lock-bot angular-automatic-lock-bot Bot locked and limited conversation to collaborators May 24, 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 area: common Issues related to APIs in the @angular/common package area: core Issues related to the framework runtime merge: caretaker note Alert the caretaker performing the merge to check the PR for an out of normal action needed or note target: major This PR is targeted for the next major release

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants