-
Notifications
You must be signed in to change notification settings - Fork 44
feat/resource/value as proxy #270
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
- fix withEntityResource - add additional type tests - make `undefined value` as the default error handling
michael-small
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Besides a call for named withEntityResource tests for error handling, most other comments are nitpicks of jsdocs or pre-existing TODO comments. But all the business logic looks solid.
| warningSpy.mockClear(); | ||
| }); | ||
|
|
||
| //TODO wait for https://github.com/ngrx/platform/pull/4932 and then add 'value' to the list |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Old outstanding TODO
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think it belongs in this PR since it would not be possible to backport it to v20. I would recommend doing a separate PR for that. If you want you can do it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No big deal, some other time then
| }, | ||
| ); | ||
|
|
||
| //TODO wait for https://github.com/ngrx/platform/pull/4932 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Old outstanding TODO
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Separate issue (see above)
| }); | ||
| }); | ||
|
|
||
| describe('Signature Tests', () => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Needs named equivalents right?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
Co-authored-by: Michael Small <[email protected]>
Co-authored-by: Michael Small <[email protected]>
Co-authored-by: Michael Small <[email protected]>
Co-authored-by: Michael Small <[email protected]>
michael-small
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Replaces the computed linkedSignal with the direct resource value, using a Proxy on the get trap to ensure fail-safe access.