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

metro-minify-terser

Package Overview
Dependencies
Maintainers
1
Versions
101
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

metro-minify-terser - npm Package Compare versions

Comparing version 0.48.0 to 0.48.1

2

package.json
{
"name": "metro-minify-terser",
"version": "0.48.0",
"version": "0.48.1",
"description": "🚇 Alternative minifier for Metro",

@@ -5,0 +5,0 @@ "main": "src/index.js",

@@ -11,6 +11,6 @@ /**

'use strict';
"use strict";
const minifier = require('./minifier');
const minifier = require("./minifier");
module.exports = minifier;
module.exports = minifier;

@@ -11,12 +11,19 @@ /**

'use strict';var _extends = Object.assign || function (target) {for (var i = 1; i < arguments.length; i++) {var source = arguments[i];for (var key in source) {if (Object.prototype.hasOwnProperty.call(source, key)) {target[key] = source[key];}}}return target;};
"use strict";
var _extends =
Object.assign ||
function(target) {
for (var i = 1; i < arguments.length; i++) {
var source = arguments[i];
for (var key in source) {
if (Object.prototype.hasOwnProperty.call(source, key)) {
target[key] = source[key];
}
}
}
return target;
};
const terser = require('terser');
const terser = require("terser");
function minifier(options) {

@@ -35,22 +42,24 @@ const result = minify(options);

function minify(_ref)
function minify(_ref) {
let code = _ref.code,
map = _ref.map,
reserved = _ref.reserved,
config = _ref.config;
const options = _extends({}, config, {
mangle: _extends({}, config.mangle, {
reserved
}),
sourceMap: map
? _extends(
{},
config.sourceMap,
{
content: map
}
)
: false
});
{let code = _ref.code,map = _ref.map,reserved = _ref.reserved,config = _ref.config;
const options = _extends({},
config, {
mangle: _extends({},
config.mangle, {
reserved }),
sourceMap: map ? _extends({},
config.sourceMap, {
content: map }) :
false });
const result = terser.minify(code, options);

@@ -66,6 +75,6 @@

// $FlowFixMe flow cannot coerce the uglify options after using spread.
map: result.map };
map: result.map
};
}
module.exports = minifier;
module.exports = minifier;
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