mirror of
https://github.com/locomotivemtl/locomotive-boilerplate.git
synced 2026-01-15 00:55:08 +08:00
18 lines
384 B
JavaScript
18 lines
384 B
JavaScript
import { module } from 'modujs';
|
|
import { FONT } from '../config';
|
|
import { whenReady } from '../utils/fonts';
|
|
|
|
export default class extends module {
|
|
constructor(m) {
|
|
super(m);
|
|
}
|
|
|
|
init() {
|
|
whenReady(FONT.EAGER).then((fonts) => this.onFontsLoaded(fonts));
|
|
}
|
|
|
|
onFontsLoaded(fonts) {
|
|
console.log('Example: Eager Fonts Loaded!', fonts)
|
|
}
|
|
}
|