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

node-inject-html-cli

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

node-inject-html-cli

A CLI interface for the node-insert-html library

  • 0.0.3
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
228
increased by11.22%
Maintainers
1
Weekly downloads
 
Created
Source

node-inject-html-cli

A CLI interface for the node-inject-html library

Usage via global install

// Install Globally
$ npm install -g node-inject-html-cli

Then...

// Inject a script to index.html
$ inject-html -f index.html --headStart="<script src='https://someanalyticsfunction.com'></script>"
// Add a meta tag to all .html files
$ inject-html -f **/*.html --headEnd="<meta name='viewport' content='width=device-width, initial-scale=1'>"

Usage via npx

// Inject a script to index.html
$ npx node-inject-html-cli -f index.html --headStart="<script src='https://someanalyticsfunction.com'></script>"
// Add a meta tag to all .html files
$ npx node-inject-html-cli -f **/*.html --headEnd='<meta name='viewport' content='width=device-width, initial-scale=1'>"

Options

$ inject-html
Usage: inject-html [options]

Options:
      --version    Show version number                                 [boolean]
  -f, --file       File to inject, supports glob patterns             [required]
      --headStart  Inject content inside the opening <head>
      --headEnd    Inject content right before the closing </head>
      --bodyStart  Inject content inside the opening <body>
      --bodyEnd    Inject content right before the closing </body>
      --help       Show help                                           [boolean]

Keywords

FAQs

Package last updated on 21 Apr 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