Scripts - Javascript module
Module with common and usefull scripts to be used along with @dipcode/dj-core
.
Exported scripts usage examples
Font Loader
const fontName: string = 'Inter';
const fontWeights: number[] = [100, 300, 400, 500, 700];
const fontLoaderScript: FontLoaderScript = new FontLoaderScript(fontName, fontWeights);
Idle
new Idle({
activityReportInSec: settings.get('SESSION_MAX_TIME'),
activityReportMode: ReportMode.Standard,
onReportUserIsIdle: () => {
location.reload();
},
});