Skip to content

Support the new Saudi riyal symbol with formatter API #1911

Description

@0xifarouk

Is your feature request related to a problem? Please describe.
Formatting currency with code "SAR", doesn't show the new Saudi riyal (⃁) symbol.

Describe the solution you'd like
The API should be updated to support it "⃁", since now it have a unicode "U+20C1".

Additional context
Here is a sample code it explain it more:

let amount = 50
let formatted = amount.formatted(.currency(code: "SAR"))
print(formatted) // SAR 50.00

let saLocale = Locale(identifier: "ar_SA")
let formattedWithSA = amount.formatted(.currency(code: "SAR").locale(saLocale))
print(formattedWithSA) // ‏٥٠٫٠٠ ر.س.‏

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions