mirror of
https://github.com/nodejs/node.git
synced 2026-11-15 10:36:53 -05:00
- Add typing for 'encoding_binding' PR-URL: https://github.com/nodejs/node/pull/59351 Reviewed-By: Daeyeon Jeong <daeyeon.dev@gmail.com> Reviewed-By: Minwoo Jung <nodecorelab@gmail.com>
9 lines
452 B
TypeScript
9 lines
452 B
TypeScript
export interface EncodingBinding {
|
|
encodeInto(source: string, dest: Uint8Array): void;
|
|
encodeUtf8String(str: string): Uint8Array;
|
|
decodeUTF8(buffer: ArrayBufferView | ArrayBuffer | SharedArrayBuffer, ignoreBOM?: boolean, hasFatal?: boolean): string;
|
|
toASCII(input: string): string;
|
|
toUnicode(input: string): string;
|
|
decodeLatin1(buffer: ArrayBufferView | ArrayBuffer | SharedArrayBuffer, ignoreBOM?: boolean, hasFatal?: boolean): string;
|
|
}
|