HTML file:
<div [hidden]="isshow">
<h1>this is a</h1>
</div>
<div [hidden]="!isshow">
<h1>this is b</h1>
</div>
component.ts:
public get isshow() {
return (this._state === 'ready');
}
The state value is changed by an EventListener, and will change from "connecting" to "ready".
What I want is to show "this is a" at the beginning then change to "this is b" when state is "ready", but looks it doesn't work. What should I do? Thanks in advance.
this is a
this is b