Skip to content

Commit

Permalink
reduce uptime plugin initial bundle size
Browse files Browse the repository at this point in the history
  • Loading branch information
mshustov committed May 5, 2020
1 parent 43205ec commit 2a0259a
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion x-pack/plugins/uptime/public/apps/plugin.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ import { CoreSetup, CoreStart, Plugin, PluginInitializerContext } from 'kibana/p
import { UMFrontendLibs } from '../lib/lib';
import { PLUGIN } from '../../common/constants';
import { FeatureCatalogueCategory } from '../../../../../src/plugins/home/public';
import { getKibanaFrameworkAdapter } from '../lib/adapters/framework/new_platform_adapter';
import { HomePublicPluginSetup } from '../../../../../src/plugins/home/public';
import { EmbeddableStart } from '../../../../../src/plugins/embeddable/public';
import { TriggersAndActionsUIPublicPluginSetup } from '../../../triggers_actions_ui/public';
Expand Down Expand Up @@ -56,6 +55,10 @@ export class UptimePlugin implements Plugin<void, void, ClientPluginsSetup, Clie
title: PLUGIN.TITLE,
async mount(params: AppMountParameters) {
const [coreStart, corePlugins] = await core.getStartServices();
const { getKibanaFrameworkAdapter } = await import(
'../lib/adapters/framework/new_platform_adapter'
);

const { element } = params;
const libs: UMFrontendLibs = {
framework: getKibanaFrameworkAdapter(coreStart, plugins, corePlugins),
Expand Down

0 comments on commit 2a0259a

Please sign in to comment.