Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

webpack-dynamic-hash

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

webpack-dynamic-hash - npm Package Compare versions

Comparing version 1.0.8 to 1.1.7

39

index.js

@@ -66,5 +66,5 @@ /**

// .js'$
var out = text.replace(/(lib-)(.*)(\.js)/g, "lib" + libHash + ".js");
out = out.replace(/(app-)(.*)(\.js)/g, "app" + appHash + ".js");
out = out.replace(/(app-)(.*)(\.c)/g, "app" + cssHash + ".c");
var out = text.replace(/(lib-)([^-]*)(\.js)/, "lib" + libHash + ".js");
out = out.replace(/(app-)([^-]*)(\.js)/, "app" + appHash + ".js");
out = out.replace(/(app-)([^-]*)(\.css)/, "app" + cssHash + ".css");
fs.writeFileSync(path.join(__dirname, init), out);

@@ -74,20 +74,17 @@ };

getAppHash(app);
setTimeout(function () {
fs.exists(path.join(__dirname, 'build/js/' + init + initHash + '.js'), function(result) {
if (result) {
fs.rename('build/js/' + init + initHash + '.js', 'build/js/' + init + '.js', function (err) {
if (err) {
console.log(err);
} else {
changeFile('build/js/' + init + '.js');
}
})
} else {
changeFile('build/js/' + init + '.js');
}
})
}, 20 );
fs.exists(path.join(__dirname, 'build/js/' + init + '.js'), function(result) {
if (!result) {
fs.rename('build/js/' + init + initHash + '.js', 'build/js/' + init + '.js', function (err) {
if (err) {
console.log(err);
} else {
changeFile('build/js/' + init + '.js');
}
})
} else {
changeFile('build/js/' + init + '.js');
}
})
};
}
fs.exists(path.join(__dirname, 'build'), function(result) {

@@ -105,5 +102,5 @@ compiler.plugin('done', function (stats) {

} catch (e) {
console.log(e);
}

@@ -110,0 +107,0 @@ };

{
"name": "webpack-dynamic-hash",
"version": "1.0.8",
"version": "1.1.7",
"main": "index.js",

@@ -5,0 +5,0 @@ "scripts": {

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc