-
-
Notifications
You must be signed in to change notification settings - Fork 205
feat(): add rxScheduleTask function #1633
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
base: main
Are you sure you want to change the base?
Conversation
Co-authored-by: Enea Jahollari <jahollarienea14@gmail.com>
Co-authored-by: Enea Jahollari <jahollarienea14@gmail.com>
Co-authored-by: Enea Jahollari <jahollarienea14@gmail.com>
Co-authored-by: Enea Jahollari <jahollarienea14@gmail.com>
Co-authored-by: Enea Jahollari <jahollarienea14@gmail.com>
### Default usage | ||
|
||
```typescript | ||
import { rxScheduleTask } from '@rx-angular/cdk/render-strategies'; |
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.
import { rxScheduleTask } from '@rx-angular/cdk/render-strategies'; | |
import { rxScheduleTask } from '@rx-angular/cdk/render-strategies'; |
I don't like it that we export it from render-strategies. Because it doesn't do anything with rendering.
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.
Can you think about better place? We had this discussion in old PR and decided that this is the best option we currently have. We can say the same about RxStrategyProvider, aren't we? This is a service for scheduling any type of work, but it's still in the render-strategies. Same reasoning goes to rxScheduleTask.
You can make it "related" to rendering by doing rxScheduleTask(() => this.cdRef.detectChanges()) ¯_(ツ)_/¯.
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.
we can introduce a new sub-package for scheduling
?
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'd go for 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.
hmmm
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 would do a rethink before and maybe see what other code we want to move
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.
Whatever we decide, please let's not have it frozen for another 1.5 years :D
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.
+1 for scheduling
Co-authored-by: Enea Jahollari <jahollarienea14@gmail.com>
Co-authored-by: Enea Jahollari <jahollarienea14@gmail.com>
Co-authored-by: Julian Jandl <julian@jandl.wien>
Introduces
rxScheduleTask
function to schedule tasks with our scheduler.This is a minimal building block for our concurrent scheduling functionality.
Includes feedback from old PR #1344.