A type that can be initialized with a string literal containing a single extended grapheme cluster.
- Xcode 8.0+
- Swift Standard Library
An extended grapheme cluster is a group of one or more Unicode scalar values that approximates a single user-perceived character. Many individual characters, such as “é”, “김”, and “🇮🇳”, can be made up of multiple Unicode scalar values. These code points are combined by Unicode’s boundary algorithms into extended grapheme clusters.
Character types conform to the
Expressible protocol. You can initialize a variable or constant of any of these types using a string literal that holds a single character.
Conforming to ExpressibleByExtendedGraphemeClusterLiteral
Expressible conformance to your custom type, implement the required initializer.