MCPcopy
hub / github.com/zxing-js/library / createCustomEncoder

Function createCustomEncoder

src/test/core/util/textEncodingFactory.ts:3–5  ·  view source on GitHub ↗
(e: string)

Source from the content-addressed store, hash-verified

1import { TextEncoder, TextDecoder } from '@zxing/text-encoding';
2
3export function createCustomEncoder(e: string) {
4 return new TextEncoder(e, { NONSTANDARD_allowLegacyEncoding: true });
5}
6
7export function createCustomDecoder(e: string) {
8 return new TextDecoder(e);

Callers 2

Encoder.spec.tsFile · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected