A workaround could be using private variables in ts file and using getters.
private _userName = "Test Name";get userName() { return this._userName;}
This is a good approach because the ts file and the html remains independent. Even if you change the _userName variable name in ts file, you dont have to make any change in the template file.