This commit is contained in:
parent
a42d1d0323
commit
523ed99f7b
@ -1,11 +1,12 @@
|
||||
import { type SpriteSpec, SPRITE_SPECS } from ".";
|
||||
import { SOUND_SPECS, SoundSpec } from "./sounds";
|
||||
|
||||
const BASE_URL = import.meta.env.BASE_URL ?? document.location;
|
||||
let BASE_URL = import.meta.env.BASE_URL || document.location;
|
||||
BASE_URL = BASE_URL.endsWith("/") ? BASE_URL.slice(0, -1) : BASE_URL;
|
||||
|
||||
export const FONT = new FontFace(
|
||||
"scientifica",
|
||||
`url(${BASE_URL}fonts/scientifica.ttf)`
|
||||
`url(${BASE_URL}/fonts/scientifica.ttf)`
|
||||
);
|
||||
FONT.load().then((font) => {
|
||||
document.fonts.add(font);
|
||||
|
Loading…
Reference in New Issue
Block a user