UNPKG

651 BPlain TextView Raw
1import { DI } from '@leanup/lib';
2
3export const importCatch = (error: unknown): void => {
4 console.warn(error);
5};
6
7export const run = (name: string, version: string | null, bootstrap: Function): void => {
8 DI.register('Framework', {
9 name,
10 version,
11 });
12 import(
13 /* webpackMode: "eager" */
14 /* webpackChunkName: "shares.register" */
15 './shares/register'
16 )
17 .then(() => {
18 import(
19 /* webpackMode: "eager" */
20 /* webpackChunkName: "shares.routing" */
21 './shares/routing'
22 )
23 .then(() => {
24 bootstrap();
25 })
26 .catch(importCatch);
27 })
28 .catch(importCatch);
29};