strip-comments
Advanced tools
Comparing version 1.0.1 to 1.0.2
14
index.js
@@ -108,5 +108,15 @@ /*! | ||
// strip all by default, including `ingored` comments. | ||
const defaults = { block: false, line: false, safe: false, first: false }; | ||
const defaults = { | ||
// we shouldn't care about this here since our goal is to strip comments, | ||
// not transpiling, and this has been a common cause of parsing issues | ||
allowReturnOutsideFunction: true, | ||
block: false, | ||
line: false, | ||
safe: false, | ||
first: false, | ||
plugins: [] | ||
}; | ||
const opts = assign({}, defaults, options); | ||
opts.plugins = ['objectRestSpread']; | ||
opts.plugins.push('objectRestSpread'); | ||
@@ -113,0 +123,0 @@ if (typeof opts.keepProtected !== 'boolean') { |
{ | ||
"name": "strip-comments", | ||
"description": "Strip comments from code. Removes line comments, block comments, the first comment only, or all comments. Optionally leave protected comments unharmed.", | ||
"version": "1.0.1", | ||
"version": "1.0.2", | ||
"homepage": "https://github.com/jonschlinkert/strip-comments", | ||
@@ -31,2 +31,4 @@ "author": "Jon Schlinkert (https://github.com/jonschlinkert)", | ||
"keywords": [ | ||
"babel", | ||
"babylon", | ||
"block", | ||
@@ -33,0 +35,0 @@ "block comment", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
15279
158