Search code examples
angularjsangularjs-filter

Strange Symbol before Currency in AngularJS


I am using the currency filter in angularjs as shown below:

<span ng-if="!Edit">{{ object.property | currency : "£" }} </span>

However this gives me the output of

£someNumber rather than how I want it to be: £someNumber

Any suggestions as to why this is/how to fix it.

Thanks in advance.


Solution

  • Try using the html entity instead...

    <span ng-if="!Edit">{{ object.property | currency : "&pound;" }} </span>