Skip to content

runtime/decoder/decode-codepoint

function decodeCodePoint(codePoint: number): string

Defined in: studiocms/packages/studiocms/src/runtime/decoder/decode-codepoint.ts:74

Replace the code point if relevant, then convert it to a string.

number

The code point to decode.

string

The decoded code point.


function fromCodePoint(...codePoints: number[]): string

Defined in: studiocms/packages/studiocms/src/runtime/decoder/decode-codepoint.ts:38

Polyfill for String.fromCodePoint. It is used to create a string from a Unicode code point.

number[]

string


function replaceCodePoint(codePoint: number): number

Defined in: studiocms/packages/studiocms/src/runtime/decoder/decode-codepoint.ts:59

Replace the given code point with a replacement character if it is a surrogate or is outside the valid range. Otherwise return the code point unchanged.

number

number