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

karma-htmlmin-preprocessor

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

karma-htmlmin-preprocessor

A karma preprocessor plugin. Minifies Html files. Useful when using other preprocessors such as karma-ng-html2js-preprocessor and testing directive rendering.

  • 0.1.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
12
decreased by-47.83%
Maintainers
1
Weekly downloads
 
Created
Source

karma-htmlmin-preprocessor

Preprocessor for running html through html-minifier

Installation

Add karma-htmlmin-preprocessor as a devDependency to your package.json file.

{
    "devDependencies": {
        "karma": "~0.10",
        "karma-htmlmin-preprocessor": "~0.1"
    }
}

Or you can install it from the commandline:

npm install karma-htmlmin-preprocessor --save-dev

Configuration

The code below shows the sample configuration of the preprocessor.

See html-minifier documentation for all possible configuration options.

// karma.conf.js
module.exports = function(config) {
    preprocessors: {
        '**/*.html': ['html-min']
    },

    htmlMinPreprocessor: {
        // options to pass through to html-minifier
        collapseWhitespace: true
        // html-min preprocessor does not perform any actions to this object
        // see https://github.com/kangax/html-minifier for all possible options
    }

    // Rest of karma config values
};

For more information on Karma, see the homepage

Keywords

FAQs

Package last updated on 15 Jun 2015

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