1

I have an application in Angular 5, and I need to have an input formatted with thousand separators (space), but my model is a number and don't allow spaces (number expected).

My application is already developped and I don't want to change all typescript, I only want to create a directive or pipe.

Example like i want :

enter image description here

Is it possible to have a different model of Input box ?

Version :

  • Angular5

Steven

1 Answers1

1

you can create an loval variable and bind to your input. then in change event of input box cast variable to your model.

if this is helpfull tell me.

hamid_reza hobab
  • 925
  • 9
  • 21