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: Add OnPush change detection #217
Conversation
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.
In your application, what is required in order to use this component without OnPush?
@@ -130,6 +131,7 @@ export class DayCalendarComponent implements OnInit, OnChanges, ControlValueAcce | |||
} | |||
|
|||
writeValue(value: CalendarValue): void { | |||
console.log('inputValue equal: ', this.inputValue === value); |
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.
pls remove
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.
oh sry, removed
I will not use it without OnPush, because I use OnPush in the whole application and I don't wanna lose any performance. |
The question is, is there a workaround? because currently it makes it harder to develop new features to this component. |
I don't know any workaround. I don't think harder to develop. Read https://angular-2-training-book.rangle.io/handout/change-detection/change_detection_strategy_onpush.html. |
I see there is a lot of over head for implementing new features. Maybe in the future when I will feel that there are no more features that I would like to add, then I will add this capability. Sorry for the time you wasted on implementing this feature - I learned from it a lot. |
What kind of over head do you see? |
adding |
No description provided.