Can i check storage in app.component.ts file for menu showing

app.component.ts

this.storage.get('id').then((id) => {
				  
		this.resp = user_id;
	})

this.pages = [
		{ title: 'Home', component: HomePage },
		{ title: 'Logout', component: Logout }
    ];

html

<ion-list  [hidden]="!resp">
      <button menuClose ion-item  *ngFor="let q of pages " (click)="openPage(q)">
        {{q.title}}
      </button>
    </ion-list>

when id is null then ion-list will be hidden. Thanks in advanced.

And what is your question?
Does this code work?
Doesn’t it work? Are you expecting something else than what happens?

Actually i want to show menu if id is not null. but when id is null then ion-list is showen.

I’m confused. The menu is inside the <ion-list>, so how can they be displayed under mutually exclusive conditions?