MCPcopy Create free account
hub / github.com/fontsource/fontsource / getHeader

Function getHeader

packages/core/tests/conversion.test.ts:5–8  ·  view source on GitHub ↗
(bytes: Uint8Array, length = 4)

Source from the content-addressed store, hash-verified

3import { loadStaticFontFixture } from './font-fixture';
4
5const getHeader = (bytes: Uint8Array, length = 4): string =>
6 Array.from(bytes.slice(0, length))
7 .map((byte) => byte.toString(16).padStart(2, '0'))
8 .join('');
9
10describe('convertFont smoke tests', () => {
11 it('converts a TTF fixture into multiple output formats', async () => {

Callers 1

conversion.test.tsFile · 0.85

Calls 1

toStringMethod · 0.80

Tested by

no test coverage detected