1.0.4 • Published 3 years ago
version-control-webpack-plugin v1.0.4
plugins: [new VersionControlWebpackPlugin()]
if (window._VERSION_CONTROL) {
window._VERSION_CONTROL.checkVersion(({ success, serverVersion, currentVersion }) => {
if (success) {
if (serverVersion !== currentVersion) {
if (isRwClient) {
// notice client to reflesh
} else {
window.location.reload(1);
}
}
} else {
console.warn(`check vresion failed!`);
}
});
}