Skip to content
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

feat(signals): add withHooks signature with factory input #4208

Merged
merged 10 commits into from Jan 12, 2024

Conversation

rainerhahnekamp
Copy link
Contributor

This PR re-introduces the injection context
into hooks after they were removed in e21df19.

PR Checklist

Please check if your PR fulfills the following requirements:

PR Type

What kind of change does this PR introduce?

[ ] Bugfix
[x] Feature
[ ] Code style update (formatting, local variables)
[ ] Refactoring (no functional changes, no api changes)
[ ] Build related changes
[ ] CI related changes
[ ] Documentation content changes
[ ] Other... Please describe:

What is the current behavior?

Currently, hooks have no way to access the dependency injection.

Closes #4201

What is the new behavior?

Hook can access DI.

Does this PR introduce a breaking change?

[ ] Yes
[x] No

Other information

This PR re-introduces the injection context
into hooks after they were removed in e21df19.
Copy link

netlify bot commented Jan 9, 2024

Deploy Preview for ngrx-io canceled.

Built without sensitive environment variables

Name Link
🔨 Latest commit 7ca50d6
🔍 Latest deploy log https://app.netlify.com/sites/ngrx-io/deploys/65a03a9c3e985d0008e4441b

modules/signals/src/with-hooks.ts Outdated Show resolved Hide resolved
modules/signals/src/with-hooks.ts Outdated Show resolved Hide resolved
modules/signals/src/with-hooks.ts Outdated Show resolved Hide resolved
modules/signals/spec/signal-store.spec.ts Outdated Show resolved Hide resolved
@markostanimirovic markostanimirovic changed the title feat(signals): hooks with injection context feat(signals): add withHooks signature with factory input Jan 11, 2024
rainerhahnekamp and others added 6 commits January 11, 2024 19:41
Co-authored-by: Marko Stanimirović <markostanimirovic95@gmail.com>
Co-authored-by: Marko Stanimirović <markostanimirovic95@gmail.com>
Co-authored-by: Marko Stanimirović <markostanimirovic95@gmail.com>
@rainerhahnekamp
Copy link
Contributor Author

Pushed latest changes as requested and updated merged from main

@timdeschryver timdeschryver merged commit 916fba0 into ngrx:main Jan 12, 2024
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

provide injection context to onDestroy
3 participants