webpack-strip-block
Advanced tools
Comparing version 0.1.0 to 0.1.1
@@ -7,3 +7,3 @@ /*jslint node:true */ | ||
function StripBlockLoader(content) { | ||
var query = loaderUtils.parseQuery(this.query); | ||
var query = this.query && typeof this.query === 'string' ? loaderUtils.parseQuery(this.query) : {}; | ||
var startComment = query.start || 'develblock:start'; | ||
@@ -10,0 +10,0 @@ var endComment = query.end || 'develblock:end'; |
{ | ||
"name": "webpack-strip-block", | ||
"version": "0.1.0", | ||
"version": "0.1.1", | ||
"description": "Webpack plugin to strip blocks of code that's only intended for development purposes", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
@@ -48,1 +48,18 @@ Webpack Strip Block | ||
``` | ||
### Webpack 2 | ||
```javascript | ||
{ | ||
rules: [ | ||
{ | ||
test: /\.js$/, | ||
enforce: 'pre', | ||
exclude: /(node_modules|bower_components|\.spec\.js)/, | ||
use: [ | ||
'webpack-strip-block?start=devcode:start&end=devcode:end' | ||
] | ||
} | ||
] | ||
} | ||
``` |
Sorry, the diff of this file is not supported yet
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
3686
65