How to format number
exemple :
3850 —> 3 850
215800 --> 215 800
if you want show with comma separator use here code
{{model.Sallary | number : fractionSize}}
after model use | number : fractionSize
but if you want use space separator you must define pipe
thankyou !!
but How to define pipes ?
like here code
import {Pipe} from ‘@angular/core’
@Pipe({
name: ‘seperatorWitSpace’
})
export class SeperatorWitSpacePipe {
transform(value: number, args: string): string {
//seperate number and return this
}
}
and for use in html file like here
<span> {{item.Sallary | seperatorWitSpace}} </span>
Sorry , I do not understand
read this