Skip to content

Commit

Permalink
Servers assets directly from node modules after the package is built
Browse files Browse the repository at this point in the history
  • Loading branch information
TinaHeiligers committed Nov 3, 2022
1 parent 4b0f296 commit c8e9380
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion packages/core/apps/core-apps-server-internal/src/core_app.ts
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,10 @@ export class CoreAppsService {
}

private registerStaticDirs(core: InternalCoreSetup | InternalCorePreboot) {
core.http.registerStaticDir('/ui/{path*}', Path.resolve(__dirname, './assets'));
core.http.registerStaticDir(
'/ui/{path*}',
fromRoot('node_modules/@kbn/core-apps-server-internal/assets')
);

core.http.registerStaticDir(
'/node_modules/@kbn/ui-framework/dist/{path*}',
Expand Down

0 comments on commit c8e9380

Please sign in to comment.