Skip to content

Commit dbe7376

Browse files
committed
Merge branch 'master' into extract-to-parser-helpers-extended
Conflicts: lib/dependencies/AMDPlugin.js
2 parents 41e689a + adb4b70 commit dbe7376

7 files changed

Lines changed: 333 additions & 354 deletions

File tree

README.md

Lines changed: 39 additions & 63 deletions
Original file line numberDiff line numberDiff line change
@@ -119,121 +119,96 @@ or are automatically applied via regex from your webpack configuration.
119119

120120
|Name|Status|Description|
121121
|:--:|:----:|:----------|
122-
|<img width="48" height="48" src="https://worldvectorlogo.com/logos/json.svg">|![json-npm]|Loads a JSON file (included by default)|
123-
|<img width="48" height="48" src="https://cdn.rawgit.com/json5/json5-logo/master/json5-logo.svg">|![json5-npm]|Loads and transpiles a JSON 5 file|
124-
|<img width="48" height="48" src="https://worldvectorlogo.com/logos/coffeescript.svg">|![cson-npm]|Loads and transpiles a CSON file|
122+
|<a href="https://github.com/webpack/json-loader"><img width="48" height="48" src="https://worldvectorlogo.com/logos/json.svg"></a>|![json-npm]|Loads a JSON file (included by default)|
123+
|<a href="https://github.com/webpack/json5-loader"><img width="48" height="48" src="https://cdn.rawgit.com/json5/json5-logo/master/json5-logo.svg"></a>|![json5-npm]|Loads and transpiles a JSON 5 file|
124+
|<a href="https://github.com/awnist/cson-loader"><img width="48" height="48" src="https://worldvectorlogo.com/logos/coffeescript.svg"></a>|![cson-npm]|Loads and transpiles a CSON file|
125125

126126

127-
[json]: https://github.com/webpack/json-loader
128127
[json-npm]: https://img.shields.io/npm/v/json-loader.svg
129-
[json5]: https://github.com/webpack/json5-loader
130128
[json5-npm]: https://img.shields.io/npm/v/json5-loader.svg
131-
[cson]: https://github.com/awnist/cson-loader
132129
[cson-npm]: https://img.shields.io/npm/v/cson-loader.svg
133130

134131
#### Transpiling
135132

136133
|Name|Status|Description|
137134
|:--:|:----:|:----------|
138-
|`<script>`|![script-npm]|Executes a JavaScript file once in global context (like in script tag), requires are not parsed|
139-
|<img width="48" height="48" title="babel-loader" src="https://worldvectorlogo.com/logos/babel-10.svg">|[![babel-npm]][babel]|Loads ES2015+ code and transpiles to ES5 using <a href="https://github.com/babel/babel">Babel</a>|
140-
|<img width="48" height="48" src="https://google.github.com/traceur-compiler/logo/tc.svg">|![traceur-npm]|Loads ES2015+ code and transpiles to ES5 using [Traceur](https://github.com/google/traceur)|
141-
|<img width="48" height="48" src="https://cdn.rawgit.com/Microsoft/TypeScript/master/doc/logo.svg">|![type-npm]|Loads TypeScript like JavaScript|
142-
|<img width="48" height="48" src="https://worldvectorlogo.com/logos/coffeescript.svg">|![coffee-npm]|Loads CoffeeScript like JavaScript|
135+
|<a href="https://github.com/webpack/script-loader">`<script>`</a>|![script-npm]|Executes a JavaScript file once in global context (like in script tag), requires are not parsed|
136+
|<a href="https://github.com/babel/babel-loader"><img width="48" height="48" title="babel-loader" src="https://worldvectorlogo.com/logos/babel-10.svg"></a>|![babel-npm]|Loads ES2015+ code and transpiles to ES5 using <a href="https://github.com/babel/babel">Babel</a>|
137+
|<a href="https://github.com/jupl/traceur-loader"><img width="48" height="48" src="https://google.github.com/traceur-compiler/logo/tc.svg"></a>|![traceur-npm]|Loads ES2015+ code and transpiles to ES5 using [Traceur](https://github.com/google/traceur)|
138+
|<a href="https://github.com/andreypopp/typescript-loader"><img width="48" height="48" src="https://cdn.rawgit.com/Microsoft/TypeScript/master/doc/logo.svg"></a>|![type-npm]|Loads TypeScript like JavaScript|
139+
|<a href="https://github.com/webpack/coffee-loader"><img width="48" height="48" src="https://worldvectorlogo.com/logos/coffeescript.svg"></a>|![coffee-npm]|Loads CoffeeScript like JavaScript|
143140

144141

145-
[script]: https://github.com/webpack/script-loader
146142
[script-npm]: https://img.shields.io/npm/v/script-loader.svg
147-
[babel]: https://github.com/babel/babel-loader
148143
[babel-npm]: https://img.shields.io/npm/v/babel-loader.svg
149-
[traceur]: https://github.com/jupl/traceur-loader
150144
[traceur-npm]: https://img.shields.io/npm/v/traceur-loader.svg
151-
[coffee]: https://github.com/webpack/coffee-loader
152145
[coffee-npm]: https://img.shields.io/npm/v/coffee-loader.svg
153-
[type]: https://github.com/andreypopp/typescript-loader
154146
[type-npm]: https://img.shields.io/npm/v/typescript-loader.svg
155147

156148
#### Templating
157149

158150
|Name|Status|Description|
159151
|:--:|:----:|:----------|
160-
|<img width="48" height="48" src="https://worldvectorlogo.com/logos/html5.svg">|![html-npm]|Exports HTML as string, require references to static resources|
161-
|<img width="48" height="48" src="https://cdn.rawgit.com/pugjs/pug-logo/master/SVG/pug-final-logo-_-colour-128.svg">|![pug-npm]|Loads Pug templates and returns a function|
162-
|<img width="48" height="48" src="https://worldvectorlogo.com/logos/jade-3.svg">|![jade-npm]|Loads Jade templates and returns a function|
163-
|<img width="48" height="48" src="https://worldvectorlogo.com/logos/markdown.svg">|![md-npm]|Compiles Markdown to HTML|
164-
|<img width="48" height="48" src="http://posthtml.github.io/posthtml/logo.svg">|![posthtml-npm]|Loads and transforms a HTML file using [PostHTML](https://github.com/posthtml/posthtml)|
165-
|<img width="48" height="48" src="https://worldvectorlogo.com/logos/handlebars-1.svg">|![hbs-npm]| Compiles Handlebars to HTML|
152+
|<a href="https://github.com/webpack/html-loader"><img width="48" height="48" src="https://worldvectorlogo.com/logos/html5.svg"></a>|![html-npm]|Exports HTML as string, require references to static resources|
153+
|<a href="https://github.com/pugjs/pug-loader"><img width="48" height="48" src="https://cdn.rawgit.com/pugjs/pug-logo/master/SVG/pug-final-logo-_-colour-128.svg"></a>|![pug-npm]|Loads Pug templates and returns a function|
154+
|<a href="https://github.com/webpack/jade-loader"><img width="48" height="48" src="https://worldvectorlogo.com/logos/jade-3.svg"></a>|![jade-npm]|Loads Jade templates and returns a function|
155+
|<a href="https://github.com/peerigon/markdown-loader"><img width="48" height="48" src="https://worldvectorlogo.com/logos/markdown.svg"></a>|![md-npm]|Compiles Markdown to HTML|
156+
|<a href="https://github.com/posthtml/posthtml-loader"><img width="48" height="48" src="http://posthtml.github.io/posthtml/logo.svg"></a>|![posthtml-npm]|Loads and transforms a HTML file using [PostHTML](https://github.com/posthtml/posthtml)|
157+
|<a href="https://github.com/altano/handlebars-loader"><img width="48" height="48" src="https://worldvectorlogo.com/logos/handlebars-1.svg"></a>|![hbs-npm]| Compiles Handlebars to HTML|
166158

167159

168-
[html]: https://github.com/webpack/html-loader
169160
[html-npm]: https://img.shields.io/npm/v/html-loader.svg
170-
[pug]: https://github.com/pugjs/pug-loader
171161
[pug-npm]: https://img.shields.io/npm/v/pug-loader.svg
172-
[jade]: https://github.com/webpack/jade-loader
173162
[jade-npm]: https://img.shields.io/npm/v/jade-loader.svg
174-
[md]: https://github.com/peerigon/markdown-loader
175163
[md-npm]: https://img.shields.io/npm/v/markdown-loader.svg
176-
[posthtml]: https://github.com/posthtml/posthtml-loader
177164
[posthtml-npm]: https://img.shields.io/npm/v/posthtml-loader.svg
178-
[hbs]: https://github.com/altano/handlebars-loader
179165
[hbs-npm]: https://img.shields.io/npm/v/handlebars-loader.svg
180166

181167
#### Styling
182168

183169
|Name|Status|Description|
184170
|:--:|:----:|:----------|
185-
|`<style>`|![style-npm]|Add exports of a module as style to DOM|
186-
|<img width="48" height="48" src="https://worldvectorlogo.com/logos/css-3.svg">|![css-npm]|Loads CSS file with resolved imports and returns CSS code|
187-
|<img width="48" height="48" src="https://worldvectorlogo.com/logos/less-63.svg">|![less-npm]|Loads and compiles a LESS file|
188-
|<img width="48" height="48" src="https://worldvectorlogo.com/logos/sass-1.svg">|![sass-npm]|Loads and compiles a SASS/SCSS file|
189-
|<img width="48" height="48" src="https://worldvectorlogo.com/logos/stylus.svg">|![stylus-npm]|Loads and compiles a Stylus file|
190-
|<img width="48" height="48" src="https://worldvectorlogo.com/logos/postcss.svg">|![postcss-npm]|Loads and transforms a CSS/SSS file using [PostCSS](http://postcss.org)|
191-
192-
[style]: https://github.com/webpack/style-loader
171+
|<a href="https://github.com/webpack/style-loader">`<style>`|![style-npm]|Add exports of a module as style to DOM|
172+
|<a href="https://github.com/webpack/css-loader"><img width="48" height="48" src="https://worldvectorlogo.com/logos/css-3.svg"></a>|![css-npm]|Loads CSS file with resolved imports and returns CSS code|
173+
|<a href="https://github.com/webpack/less-loader"><img width="48" height="48" src="https://worldvectorlogo.com/logos/less-63.svg"></a>|![less-npm]|Loads and compiles a LESS file|
174+
|<a href="https://github.com/jtangelder/sass-loader"><img width="48" height="48" src="https://worldvectorlogo.com/logos/sass-1.svg"></a>|![sass-npm]|Loads and compiles a SASS/SCSS file|
175+
|<a href="https://github.com/shama/stylus-loader"><img width="48" height="48" src="https://worldvectorlogo.com/logos/stylus.svg"></a>|![stylus-npm]|Loads and compiles a Stylus file|
176+
|<a href="https://github.com/postcss/postcss-loader"><img width="48" height="48" src="https://worldvectorlogo.com/logos/postcss.svg"></a>|![postcss-npm]|Loads and transforms a CSS/SSS file using [PostCSS](http://postcss.org)|
177+
178+
193179
[style-npm]: https://img.shields.io/npm/v/style-loader.svg
194-
[css]: https://github.com/webpack/css-loader
195180
[css-npm]: https://img.shields.io/npm/v/css-loader.svg
196-
[less]: https://github.com/webpack/less-loader
197181
[less-npm]: https://img.shields.io/npm/v/less-loader.svg
198-
[sass]: https://github.com/jtangelder/sass-loader
199182
[sass-npm]: https://img.shields.io/npm/v/sass-loader.svg
200-
[stylus]: https://github.com/shama/stylus-loader
201183
[stylus-npm]: https://img.shields.io/npm/v/stylus-loader.svg
202-
[postcss]: https://github.com/postcss/postcss-loader
203184
[postcss-npm]: https://img.shields.io/npm/v/postcss-loader.svg
204185

205186
#### Linting && Testing
206187

207188
|Name|Status|Description|
208189
|:--:|:----:|:----------|
209-
|<img width="48" height="48" src="https://worldvectorlogo.com/logos/mocha.svg">|![mocha-npm]|Tests with mocha (Browser/NodeJS)|
210-
|<img width="48" height="48" src="https://worldvectorlogo.com/logos/eslint.svg">|![eslint-npm]|PreLoader for linting code using ESLint|
211-
|<img width="48" height="48" src="http://jshint.com/res/jshint-dark.png">|![jshint-npm]|PreLoader for linting code using JSHint|
212-
|<img width="48" height="48" src="https://worldvectorlogo.com/logos/jscs.svg">|![jscs-npm]|PreLoader for code style checking using JSCS|
190+
|<a href="https://github.com/webpack/mocha-loader"><img width="48" height="48" src="https://worldvectorlogo.com/logos/mocha.svg"></a>|![mocha-npm]|Tests with mocha (Browser/NodeJS)|
191+
|<a href="https://github.com/MoOx/eslint-loader"><img width="48" height="48" src="https://worldvectorlogo.com/logos/eslint.svg"></a>|![eslint-npm]|PreLoader for linting code using ESLint|
192+
|<a href="https://github.com/webpack/jslint-loader"><img width="48" height="48" src="http://jshint.com/res/jshint-dark.png"></a>|![jshint-npm]|PreLoader for linting code using JSHint|
193+
|<a href="https://github.com/unindented/jscs-loader"><img width="48" height="48" src="https://worldvectorlogo.com/logos/jscs.svg"></a>|![jscs-npm]|PreLoader for code style checking using JSCS|
213194

214195

215-
[mocha]: https://github.com/webpack/mocha-loader
216196
[mocha-npm]: https://img.shields.io/npm/v/mocha-loader.svg
217-
[eslint]: https://github.com/MoOx/eslint-loader
218197
[eslint-npm]: https://img.shields.io/npm/v/eslint-loader.svg
219-
[jshint]: https://github.com/webpack/jslint-loader
220198
[jshint-npm]: https://img.shields.io/npm/v/jslint-loader.svg
221-
[jscs]: https://github.com/unindented/jscs-loader
222199
[jscs-npm]: https://img.shields.io/npm/v/jscs-loader.svg
223200

224201
#### Frameworks
225202

226203
|Name|Status|Description|
227204
|:--:|:----:|:----------|
228-
|<img width="48" height="48" src="https://worldvectorlogo.com/logos/vue-9.svg">|![vue-npm]|Loads and compiles Vue Components|
229-
|<img width="48" height="48" src="https://worldvectorlogo.com/logos/polymer.svg">|![polymer-npm]|Process HTML & CSS with preprocessor of choice and `require()` Web Components like first-class modules|
230-
|<img width="48" height="48" src="https://worldvectorlogo.com/logos/angular-icon-1.svg">|![angular-npm]| Loads and compiles Angular 2 Components|
205+
|<a href="https://github.com/vue/vue-loader"><img width="48" height="48" src="https://worldvectorlogo.com/logos/vue-9.svg"></a>|![vue-npm]|Loads and compiles Vue Components|
206+
|<a href="https://github.com/JonDum/polymer-loader"><img width="48" height="48" src="https://worldvectorlogo.com/logos/polymer.svg"></a>|![polymer-npm]|Process HTML & CSS with preprocessor of choice and `require()` Web Components like first-class modules|
207+
|<a href="https://github.com/TheLarkInn/angular2-template-loader"><img width="48" height="48" src="https://worldvectorlogo.com/logos/angular-icon-1.svg"></a>|![angular-npm]| Loads and compiles Angular 2 Components|
208+
231209

232-
[vue]: https://github.com/vue/vue-loader
233210
[vue-npm]: https://img.shields.io/npm/v/vue-loader.svg
234-
[polymer]: https://github.com/JonDum/polymer-loader
235211
[polymer-npm]: https://img.shields.io/npm/v/polymer-loader.svg
236-
[angular]: https://github.com/TheLarkInn/angular2-template-loader
237212
[angular-npm]: https://img.shields.io/npm/v/angular2-template-loader.svg
238213

239214
### Performance
@@ -282,52 +257,53 @@ If you want to discuss something or just need help, [here is our Gitter room](ht
282257
<table>
283258
<tbody>
284259
<tr>
285-
<td align="center">
260+
<td align="center" valign="top">
286261
<img width="150" height="150" src="https://github.com/sokra.png?s=150">
287262
<br>
288263
<a href="https://github.com/sokra">Tobias Koppers</a>
289264
<p>Core</p>
290265
<br>
291266
<p>Founder of webpack</p>
292267
</td>
293-
<td align="center">
268+
<td align="center" valign="top">
294269
<img width="150" height="150" src="https://github.com/jhnns.png?s=150">
295270
<br>
296271
<a href="https://github.com/jhnns">Johannes Ewald</a>
297272
<p>Loaders &amp; Plugins</p>
298273
<br>
299274
<p>Early adopter of webpack</p>
300275
</td>
301-
<td align="center" width="20%">
276+
<td align="center" width="20%" valign="top">
302277
<img width="150" height="150" src="https://github.com/TheLarkInn.png?s=150">
303278
<br>
304279
<a href="https://github.com/TheLarkInn">Sean T. Larkin</a>
305280
<p>Public Relations</p>
306281
<br>
307282
<p>Founder of the core team</p>
308283
</td>
309-
<td align="center">
284+
<td align="center" valign="top">
310285
<img width="150" height="150" src="https://github.com/bebraw.png?s=150">
311286
<br>
312287
<a href="https://github.com/bebraw">Juho Vepsäläinen</a>
313288
<p>Documentation<p>
314289
<br>
315290
<p>Author</p>
316291
<a href="https://leanpub.com/survivejs-webpack">
317-
<img height="15" src="proxy.php?url=https%3A%2F%2Fcloud.githubusercontent.com%2Fassets%2F1365881%2F20286923%2F93e325c0-aac9-11e6-964d-cabe218c584c.png">Webpack
292+
<img height="15" src="proxy.php?url=https%3A%2F%2Fcloud.githubusercontent.com%2Fassets%2F1365881%2F20286923%2F93e325c0-aac9-11e6-964d-cabe218c584c.png">
318293
</a>
294+
<br>
319295
</td>
320-
<td align="center">
296+
<td align="center" valign="top">
321297
<img width="150" height="150" src="https://github.com/spacek33z.png?s=150">
322298
<br>
323299
<a href="https://github.com/spacek33z">Kees Kluskens</a>
324300
<p>Development</p>
325301
<br>
326-
<br>
327302
<p>Sponsor<p>
328303
<a href="https://codeyellow.nl/">
329-
<img height="15" src="proxy.php?url=https%3A%2F%2Fcloud.githubusercontent.com%2Fassets%2F1365881%2F20286583%2Fad62eb04-aac7-11e6-9c14-a0fef35b9b56.png">
304+
<img height="15px" src="proxy.php?url=https%3A%2F%2Fcloud.githubusercontent.com%2Fassets%2F1365881%2F20286583%2Fad62eb04-aac7-11e6-9c14-a0fef35b9b56.png">
330305
</a>
306+
<br>
331307
</td>
332308
</tr>
333309
</tbody>

lib/AsyncDependenciesBlock.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,4 +50,4 @@ module.exports = class AsyncDependenciesBlock extends DependenciesBlock {
5050
});
5151
}
5252
}
53-
}
53+
};

lib/NoEmitOnErrorsPlugin.js

Lines changed: 14 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -2,18 +2,21 @@
22
MIT License http://www.opensource.org/licenses/mit-license.php
33
Author Tobias Koppers @sokra
44
*/
5-
function NoEmitOnErrorsPlugin() {}
5+
"use strict";
66

7-
module.exports = NoEmitOnErrorsPlugin;
8-
NoEmitOnErrorsPlugin.prototype.apply = function(compiler) {
9-
compiler.plugin("should-emit", function(compilation) {
10-
if(compilation.errors.length > 0)
11-
return false;
12-
});
13-
compiler.plugin("compilation", function(compilation) {
14-
compilation.plugin("should-record", function() {
7+
class NoEmitOnErrorsPlugin {
8+
apply(compiler) {
9+
compiler.plugin("should-emit", (compilation) => {
1510
if(compilation.errors.length > 0)
1611
return false;
1712
});
18-
});
19-
};
13+
compiler.plugin("compilation", (compilation) => {
14+
compilation.plugin("should-record", () => {
15+
if(compilation.errors.length > 0)
16+
return false;
17+
});
18+
});
19+
}
20+
}
21+
22+
module.exports = NoEmitOnErrorsPlugin;

0 commit comments

Comments
 (0)