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

docpad-plugin-uglify

Package Overview
Dependencies
Maintainers
2
Versions
8
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

docpad-plugin-uglify - npm Package Compare versions

Comparing version 2.1.0 to 2.2.0

16

out/uglify.plugin.js

@@ -17,9 +17,15 @@ // Generated by CoffeeScript 1.6.3

UglifyPlugin.prototype.config = {
all: true
};
UglifyPlugin.prototype.renderDocument = function(opts) {
var extension;
extension = opts.extension;
var extension, file;
file = opts.file, extension = opts.extension;
if (extension === 'js') {
opts.content = require('uglify-js').minify(opts.content, {
fromString: true
}).code;
if ((this.getConfig().all === true && file.get('minify') !== false) || (file.get('minify') === true)) {
opts.content = require('uglify-js').minify(opts.content, {
fromString: true
}).code;
}
}

@@ -26,0 +32,0 @@ return this;

{
"name": "docpad-plugin-uglify",
"version": "2.1.0",
"version": "2.2.0",
"description": "Adds support for uglify-js's parser/compressor to DocPad",

@@ -5,0 +5,0 @@ "homepage": "http://docpad.org/plugin/uglify",

@@ -18,2 +18,6 @@ # [UglifyJS](https://github.com/mishoo/UglifyJS) Plugin for [DocPad](http://docpad.org)

## Configuration
By default we will minify all javascript files that don't have `minify: false` in their meta data. You can turn this off by setting `plugins: uglify: all: false` in your docpad configuration file then explicitly setting `minify: true` in your meta data.
## History

@@ -20,0 +24,0 @@ [You can discover the history inside the `History.md` file](https://github.com/bevry/docpad-plugin-uglify/blob/master/History.md#files)

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