New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

move-nuxt-module

Package Overview
Dependencies
Maintainers
1
Versions
6
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

move-nuxt-module - npm Package Compare versions

Comparing version 1.2.1 to 1.3.0

44

index.js

@@ -6,26 +6,24 @@ const path = require("path");

async function asyncModule() {
const { outputDir, dirName, version, type } = this.options.moveModuleOptions;
const { buildEnv } = this.options.global;
if (buildEnv === "prod" || buildEnv === "release") {
this.nuxt.hook("generate:done", async nuxt => {
const dir = path.join(nuxt.options.rootDir, "dist", outputDir);
let entriePath = "";
if (type === "oss") {
entriePath = path.join(dir, "assets", dirName, version, "**/*.html");
} else if(type === "server") {
entriePath = path.join(dir, dirName, version, "**/*.html");
}else{
entriePath = path.join(dir, "assets", dirName, version, "**/*.html");
}
const { outputDir, dirName, version, type } = this.options.globalModuleOptions;
const moveDir = path.join(dir, dirName);
vfs.src(entriePath).pipe(vfs.dest(moveDir));
vfs.src(entriePath).pipe(
map(function(file, cb) {
fse.removeSync(file.path);
cb(null, file);
})
);
});
}
this.nuxt.hook("generate:done", async nuxt => {
const dir = path.join(nuxt.options.rootDir, "dist", outputDir);
let entriePath = "";
if (type === "oss") {
entriePath = path.join(dir, "assets", dirName, version, "**/*.html");
} else if (type === "server") {
entriePath = path.join(dir, dirName, version, "**/*.html");
} else {
entriePath = path.join(dir, "assets", dirName, version, "**/*.html");
}
const moveDir = path.join(dir, dirName);
vfs.src(entriePath).pipe(vfs.dest(moveDir));
vfs.src(entriePath).pipe(
map(function(file, cb) {
fse.removeSync(file.path);
cb(null, file);
})
);
});
}

@@ -32,0 +30,0 @@

{
"name": "move-nuxt-module",
"version": "1.2.1",
"version": "1.3.0",
"main": "index.js",

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

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