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

add-dist-header

Package Overview
Dependencies
Maintainers
1
Versions
43
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

add-dist-header

Adds a header comment to a file and saves it to your distribution folder (written in TypeScript)

  • 0.0.2
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
37
decreased by-11.9%
Maintainers
1
Weekly downloads
 
Created
Source

Add Dist Header

<img src=https://centerkey.com/graphics/center-key-logo.svg align=right width=200 alt=logo>

Adds a header comment to a file and saves it to your distribution folder

License:MIT npm Vulnerabilities Build

add-dist-header uses the name, repository, and license from your project's package.json file to create a header comment.

Example header comment:

//! my-app v0.3.7 ~ github:my-organization/my-app ~ MIT License

1) Setup

Install

Install package for node:

$ npm install --save-dev add-dist-header

2) Usage

Call add-dist-header from the "scripts" section of your package.json file.

For example:

   "scripts": {
      "add-headers": "add-dist-header build dist"
   },

Or, run from the terminal in your project home folder, such as:

$ ls package.json
package.json
$ npx add-dist-header "build" "dist"
[add-dist-header] dist/my-app.d.ts ~ length: 413
[add-dist-header] dist/my-app.js ~ length: 1569

The parameters are optional:

$ npx add-dist-header  #same as above since "build/*" "dist" are the default parameters
[add-dist-header] dist/my-app.d.ts ~ length: 413
[add-dist-header] dist/my-app.js ~ length: 1569
$ npx add-dist-header "target/my-app-cli.js"  #creates "dist/my-app.js" prepended with a comment header
[add-dist-header] dist/my-app-cli.js ~ length: 413

Keywords

FAQs

Package last updated on 29 Sep 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

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