diff --git a/packages/core/client/src/application/utils/remotePlugins.ts b/packages/core/client/src/application/utils/remotePlugins.ts index 877ea8218..702e11cd3 100644 --- a/packages/core/client/src/application/utils/remotePlugins.ts +++ b/packages/core/client/src/application/utils/remotePlugins.ts @@ -31,7 +31,7 @@ export function getRemotePlugins(requirejs: any, pluginData: PluginData[] = []): requirejs.requirejs.config({ waitSeconds: 120, paths: pluginData.reduce>((acc, cur) => { - acc[cur.packageName] = `${cur.url}?noExt`; + acc[cur.packageName] = cur.url; return acc; }, {}), }); diff --git a/packages/core/server/src/plugin-manager/options/resource.ts b/packages/core/server/src/plugin-manager/options/resource.ts index b41ee5796..d80ac292f 100644 --- a/packages/core/server/src/plugin-manager/options/resource.ts +++ b/packages/core/server/src/plugin-manager/options/resource.ts @@ -4,6 +4,8 @@ import path from 'path'; import Application from '../../application'; import { getExposeUrl } from '../clientStaticUtils'; import PluginManager from '../plugin-manager'; +//@ts-ignore +import { version } from '../../../package.json'; export default { name: 'pm', @@ -129,7 +131,7 @@ export default { try { return { ...item.toJSON(), - url: getExposeUrl(item.packageName, PLUGIN_CLIENT_ENTRY_FILE), + url: `${getExposeUrl(item.packageName, PLUGIN_CLIENT_ENTRY_FILE)}?version=${version}`, }; } catch { return false;