-
-
Save chidumennamdi/ccf891d25ced99828ca5cc7e6f4c39ad to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Component({ | |
... | |
template:` | |
{{count}} | |
<button (click)="up()">Click</button> | |
`, | |
changeDetection: ChangeDetectionStrategy.OnPush | |
}) | |
export class DOMComponent{ | |
count = 0 | |
up() { | |
this.count++ | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment