mirror of
https://github.com/lensapp/lens.git
synced 2025-05-20 05:10:56 +00:00
chore!: Make linkable-push opt-in for shared build scripts
This is because linkable-push is a non-deterministic side-effect, and thus breaks fundamentals of nx-cacheing. Running it elsewhere in later commit will give us best-of-both-worlds, where builds get cached, and linkable-push still gets run automatically when required. BREAKING CHANGE: Add "new LinkablePushPlugin()" in your "plugins" of webpack.config to restore automatic linkable-push when using "lens-webpack-build", "lens-webpack-build --watch" or just "webpack". Co-authored-by: Janne Savolainen <janne.savolainen@live.fi> Signed-off-by: Mikko Aspiala <mikko.aspiala@gmail.com>
This commit is contained in:
parent
aac6245e8c
commit
b408d5693d
@ -2,3 +2,4 @@ export { configForNode } from "./src/node-config";
|
|||||||
export { configForReact } from "./src/react-config";
|
export { configForReact } from "./src/react-config";
|
||||||
export { getMultiExportConfig } from "./src/get-multi-export-config";
|
export { getMultiExportConfig } from "./src/get-multi-export-config";
|
||||||
export { doWebpackBuild } from "./do-webpack-build";
|
export { doWebpackBuild } from "./do-webpack-build";
|
||||||
|
export { LinkablePushPlugin } from "./src/plugins/linkable-push-plugin";
|
||||||
|
|||||||
@ -26,8 +26,7 @@ exports[`get-multi-export-config given maximal package.json, when creating confi
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
}
|
||||||
LinkablePushPlugin {}
|
|
||||||
],
|
],
|
||||||
output: {
|
output: {
|
||||||
path: '/some-working-directory/dist',
|
path: '/some-working-directory/dist',
|
||||||
@ -62,8 +61,7 @@ exports[`get-multi-export-config given maximal package.json, when creating confi
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
}
|
||||||
LinkablePushPlugin {}
|
|
||||||
],
|
],
|
||||||
output: {
|
output: {
|
||||||
path: '/some-working-directory/dist/some-entrypoint',
|
path: '/some-working-directory/dist/some-entrypoint',
|
||||||
@ -99,7 +97,6 @@ exports[`get-multi-export-config given maximal package.json, when creating confi
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
LinkablePushPlugin {},
|
|
||||||
MiniCssExtractPlugin {
|
MiniCssExtractPlugin {
|
||||||
_sortedModulesCache: WeakMap { <items unknown> },
|
_sortedModulesCache: WeakMap { <items unknown> },
|
||||||
options: {
|
options: {
|
||||||
|
|||||||
@ -53,7 +53,6 @@ exports[`get-node-config given an environment, works 1`] = `
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
LinkablePushPlugin {},
|
|
||||||
],
|
],
|
||||||
"resolve": {
|
"resolve": {
|
||||||
"extensions": [
|
"extensions": [
|
||||||
|
|||||||
@ -2,7 +2,6 @@ import ForkTsCheckerPlugin from "fork-ts-checker-webpack-plugin";
|
|||||||
import type { Configuration } from "webpack";
|
import type { Configuration } from "webpack";
|
||||||
import { MakePeerDependenciesExternalPlugin } from "./plugins/make-peer-dependencies-external";
|
import { MakePeerDependenciesExternalPlugin } from "./plugins/make-peer-dependencies-external";
|
||||||
import { ProtectFromImportingNonDependencies } from "./plugins/protect-from-importing-non-dependencies";
|
import { ProtectFromImportingNonDependencies } from "./plugins/protect-from-importing-non-dependencies";
|
||||||
import { LinkablePushPlugin } from "./plugins/linkable-push-plugin";
|
|
||||||
import type { Environment } from "./runtime-values/environment";
|
import type { Environment } from "./runtime-values/environment";
|
||||||
|
|
||||||
export type GetNodeConfigParams = {
|
export type GetNodeConfigParams = {
|
||||||
@ -49,8 +48,6 @@ export const getNodeConfig = ({
|
|||||||
},
|
},
|
||||||
},
|
},
|
||||||
}),
|
}),
|
||||||
|
|
||||||
new LinkablePushPlugin(),
|
|
||||||
],
|
],
|
||||||
|
|
||||||
output: {
|
output: {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user