ngx-mask
ngx-mask copied to clipboard
Preserve decimal values on model but not on display?
Hi,
I was wondering if there was some way to preserve the decimals in a value but not displaying those decimals? What I am seeing is that as soon as a user edits the model value loses its decimals and that causes some data loss even though the user doesnt want to see it. I have a set up like this:
<input type="text" [allowNegativeNumbers]="true" mask="separator.0" thousandSeparator="," [(ngModel)]="amount">
where a model value of 99.99 after edit would turn into just 99. Is there anyway to preserve that decimal value?
Thanks