Skip to content

Commit

Permalink
remove the last TODO. url should be inlined with assetss server
Browse files Browse the repository at this point in the history
  • Loading branch information
mshustov committed Apr 27, 2020
1 parent 9f46398 commit 5e5c145
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
10 changes: 6 additions & 4 deletions src/legacy/ui/ui_render/ui_render_mixin.js
Original file line number Diff line number Diff line change
Expand Up @@ -157,13 +157,15 @@ export function uiRenderMixin(kbnServer, server, config) {
];

// These paths should align with the bundle routes configured in
// src/optimize/bundles_route/bundles_route.js
// TODO check if it still required
// src/optimize/bundles_route/bundles_route.ts
const publicPathMap = JSON.stringify({
core: `${regularBundlePath}/core/`,
core: `${regularBundlePath}/${buildHash}/core/`,
'kbn-ui-shared-deps': `${regularBundlePath}/kbn-ui-shared-deps/`,
...uiPluginIds.reduce(
(acc, pluginId) => ({ ...acc, [pluginId]: `${regularBundlePath}/plugin/${pluginId}/` }),
(acc, pluginId) => ({
...acc,
[pluginId]: `${regularBundlePath}/${buildHash}/plugin/${pluginId}/`,
}),
{}
),
});
Expand Down
1 change: 0 additions & 1 deletion src/optimize/bundles_route/bundles_route.ts
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,6 @@ export function createBundlesRoute({
})
),
// for async chunks that loaded by webpack.
// we can configure it as publicPath in webpack though
...npUiPluginPublicDirs.map(({ id, path }) =>
buildRouteForBundles({
publicPath: `${basePublicPath}/bundles/plugin/${id}/`,
Expand Down

0 comments on commit 5e5c145

Please sign in to comment.