I have a boolean variable named isTrue. When all data came in my list from api isTrue turn true. Also I have open dialog when page is loaded. I want to show close button in this dialog when isTrue = true. It is kinda loader I think. While isTrue = false my exit button has to be disappear. When it turns true my exit button should be active. But in my code it takes data only once and can't see when isTrue change
note: I am using angular cli 9.1.9
const dialogconfig = new MatDialogConfig()
dialogConfig.data = this.isTrue
this.dialogRef = this.dialog.open("loaderComponent", dialogConfig)