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

@egjs/build-helper

Package Overview
Dependencies
Maintainers
8
Versions
9
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@egjs/build-helper - npm Package Compare versions

Comparing version 0.0.3 to 0.0.4

19

index.js

@@ -0,7 +1,19 @@

const fs = require("fs");
const pkg = require(process.cwd() + "/package.json");
let copyright = `Copyright (c) ${pkg.author ? pkg.author.name || pkg.author : ""}`;
try {
const licenseFile = fs.readFileSync(process.cwd() + "/LICENSE", {encoding: "utf8"});
const result = licenseFile.match(/^copy.*$/img);
if (result && result[0]) {
copyright = result[0];
}
} catch (e) {}
const defaultBanner = `/*
Copyright (c) year-present ${pkg.author}
${copyright}
name: ${pkg.name}
license: ${pkg.license}
author: ${pkg.author}
author: ${pkg.author ? pkg.author.name || pkg.author : ""}
repository: ${pkg.repository.url}

@@ -41,3 +53,2 @@ version: ${pkg.version}

const {
year = new Date().getFullYear(),
input,

@@ -57,3 +68,3 @@ output, // string | string[]

outputOptions, // other output options
banner = defaultBanner.replace("year", year),
banner = defaultBanner,
} = options;

@@ -60,0 +71,0 @@ const nextPlugins = plugins.concat([typescriptPlugin, minifyPlugin, replacePlugin]);

{
"name": "@egjs/build-helper",
"version": "0.0.3",
"version": "0.0.4",
"description": "",

@@ -5,0 +5,0 @@ "main": "index.js",

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