MCPcopy Create free account
hub / github.com/SplootCode/splootcode / awaitFontsLoaded

Function awaitFontsLoaded

packages/editor/src/layout/layout_constants.ts:74–77  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

72}
73
74export async function awaitFontsLoaded() {
75 const promises = [document.fonts.load('16px "Karla"'), document.fonts.load("15px 'Inconsolata'")]
76 await Promise.all(promises)
77}
78
79export function preloadFonts() {
80 stringWidth('loadfontplz')

Callers 1

openFileMethod · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected