2023-03-01 09:39:41 -06:00
|
|
|
/**
|
2026-01-28 17:09:06 -08:00
|
|
|
* Copyright IBM Corp. 2021, 2026
|
2024-05-31 11:29:24 -07:00
|
|
|
* SPDX-License-Identifier: BUSL-1.1
|
2023-03-01 09:39:41 -06:00
|
|
|
*/
|
|
|
|
|
|
2020-05-18 17:02:09 -04:00
|
|
|
import Application from '@ember/application';
|
|
|
|
|
import Resolver from 'ember-resolver';
|
|
|
|
|
import loadInitializers from 'ember-load-initializers';
|
2020-11-17 11:15:42 -05:00
|
|
|
import config from 'admin/config/environment';
|
2026-01-05 15:01:29 -08:00
|
|
|
import 'ember-power-select/styles';
|
2026-02-03 13:54:32 -05:00
|
|
|
import {
|
|
|
|
|
macroCondition,
|
|
|
|
|
importSync,
|
|
|
|
|
getOwnConfig,
|
|
|
|
|
isTesting,
|
|
|
|
|
} from '@embroider/macros';
|
2026-02-24 13:48:34 -05:00
|
|
|
import { extendResolver } from 'ember-can';
|
2020-05-18 17:02:09 -04:00
|
|
|
|
|
|
|
|
export default class App extends Application {
|
|
|
|
|
modulePrefix = config.modulePrefix;
|
|
|
|
|
podModulePrefix = config.podModulePrefix;
|
2026-02-24 13:48:34 -05:00
|
|
|
Resolver = extendResolver(Resolver);
|
2020-05-18 17:02:09 -04:00
|
|
|
}
|
|
|
|
|
|
|
|
|
|
loadInitializers(App, config.modulePrefix);
|
2026-02-03 13:54:32 -05:00
|
|
|
|
|
|
|
|
if (macroCondition(getOwnConfig().startMirageWithApp && !isTesting())) {
|
|
|
|
|
const startServer = importSync('admin/mirage/config').default;
|
|
|
|
|
startServer({});
|
|
|
|
|
}
|