docs(cheatsheet): correct HostBinding decorator example (#13206)
This commit is contained in:
parent
d2e5198b93
commit
b8c839bd51
|
@ -27,10 +27,10 @@ Declares an output property that fires events that you can subscribe to with an
|
||||||
|
|
||||||
@cheatsheetItem
|
@cheatsheetItem
|
||||||
syntax(ts):
|
syntax(ts):
|
||||||
`@HostBinding('[class.valid]') isValid;`|`@HostBinding('[class.valid]')`
|
`@HostBinding('class.valid') isValid;`|`@HostBinding('class.valid')`
|
||||||
syntax(js):
|
syntax(js):
|
||||||
`ng.core.HostBinding('[class.valid]',
|
`ng.core.HostBinding('class.valid',
|
||||||
'isValid', myComponent);`|`ng.core.HostBinding('[class.valid]', 'isValid'`|`);`
|
'isValid', myComponent);`|`ng.core.HostBinding('class.valid', 'isValid'`|`);`
|
||||||
description:
|
description:
|
||||||
Binds a host element property (here, the CSS class `valid`) to a directive/component property (`isValid`).
|
Binds a host element property (here, the CSS class `valid`) to a directive/component property (`isValid`).
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue