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

fly-uglify

Package Overview
Dependencies
Maintainers
1
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

fly-uglify - npm Package Compare versions

Comparing version 0.4.0 to 1.0.0

9

index.js

@@ -5,6 +5,7 @@ const assign = require("object-assign")

module.exports = function () {
this.filter("uglify", (source, options) => {
try { return minify(source, assign({ fromString: true }, options)).code }
catch (e) { throw e }
}, { ext: ".js" })
this.filter("uglify", (data, options) => {
return assign({ ext: ".js" }, minify(data.toString(), assign({
fromString: true
}, options)))
})
}
{
"name": "fly-uglify",
"version": "0.4.0",
"version": "1.0.0",
"description": "Uglify plugin for Fly",

@@ -5,0 +5,0 @@ "license": "MIT",

@@ -7,8 +7,9 @@ const test = require("tape").test

uglify.call({
filter: function (name, transform, options) {
filter: function (name, transform) {
const res = transform("/* yay */")
t.equal(name, "uglify", "add uglify filter")
t.ok(/^\s*$/.test(transform("/* yay */")), "uglify transform")
t.equal(options.ext, ".js", "extension is .js")
t.ok(/^\s*$/.test(res.code), "uglify transform")
t.equal(res.ext, ".js", "extension is .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