ngx-mask issue in Angular 9

1.3k Views Asked by At

I have used ngx-mask dynamically in my app by assigning a variable to it.

This is nullable variable and input shows undefined when the variable is null or undefined.

This is happening after I upgrade Angular from ver-8 to ver-9.

It was working fine on Angular 8.

I want mask in input does nothing when the variable is null or undefined. Please help me.

1

There are 1 best solutions below

0
On

I find the solution.

The problem was I was using value instead of ngModel to apply value on input.

When I changed it to ngModel, the issue resolved.