You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
and [here](https://medium.com/@preethikasireddy/javascript-modules-part-2-module-bundling-5020383cf306#.lfnspler2).
@@ -180,10 +180,10 @@ The things that are bundled are only the things that you explicitly required acr
180
180
### Loaders
181
181
182
182
As you probably noticed, I did something strange in the above example. I `required` a css file in
183
-
a javascript file.
183
+
a JavaScript file.
184
184
185
185
The really cool, and interesting thing about webpack is that you can `require` more than just
186
-
javascript files.
186
+
JavaScript files.
187
187
188
188
There is this thing in webpack called a loader. Using these loaders, you can
189
189
`require` anything from `.css` and `.html` to `.png` files.
@@ -203,7 +203,7 @@ This is just a single example of the many loaders you can use with webpack.
203
203
### Plugins
204
204
205
205
Plugins, like the name suggests, add extra functionality to webpack. One frequently used plugin is
206
-
the `UglifyJsPlugin`, which lets you minify your javascript code. We'll cover how to use this later.
206
+
the `UglifyJsPlugin`, which lets you minify your JavaScript code. We'll cover how to use this later.
207
207
208
208
## Your Config File
209
209
@@ -306,7 +306,7 @@ You can also add the [OrderOccurencePlugin](https://webpack.github.io/docs/list-
306
306
307
307
To be honest I'm not sure how the underlying mechanisms work, but in the current [webpack2 beta it's included by default](https://gist.github.com/sokra/27b24881210b56bbaff7) so I include it as well.
308
308
309
-
```javascript
309
+
```JavaScript
310
310
// webpack.config.js
311
311
var path =require('path')
312
312
var webpack =require('webpack')
@@ -328,14 +328,14 @@ module.exports = {
328
328
}
329
329
```
330
330
331
-
So now we have written a config that allows us to minify and bundle our javascript. This bundle
331
+
So now we have written a config that allows us to minify and bundle our JavaScript. This bundle
332
332
could be copied and pasted into another project's directory, and thrown into a `<script>` tag there.
333
333
You can skip to the [conclusion](#conclusion) if you only care about the basics of using webpack
334
-
with *only javascript*.
334
+
with *only JavaScript*.
335
335
336
336
## A More Complete Example
337
337
338
-
Alternatively, because webpack can do more than just work with javascript, you can avoid the
338
+
Alternatively, because webpack can do more than just work with JavaScript, you can avoid the
339
339
copy-pasting and manage your entire project with webpack.
340
340
341
341
In the following section, we are going to create a very simple website using webpack. If you wish to
@@ -357,7 +357,7 @@ MyDirectory
357
357
1.[Introducing Loaders](#introducing-loaders) - We will add loaders, which allow us to add CSS to our bundle.
358
358
2.[Adding More Plugins](#adding-more-plugins) - We will add a plugin that'll help us create/use an HTML file.
359
359
3.[The Development Server](#the-development-server) - We'll split our webpack config into separate `development` and `production` files. Then use the webpack-dev-server to view our website and enable HMR.
360
-
4.[Start Coding](#start-coding) - We will actually write some javascript.
360
+
4.[Start Coding](#start-coding) - We will actually write some JavaScript.
361
361
362
362
#### Introducing Loaders
363
363
@@ -405,7 +405,7 @@ Going over the new properties one by one:
405
405
* test - A regular expression to match the loader with a file
406
406
* loaders - Which loaders to use for files that match the test
407
407
408
-
This time when you run `webpack`, if we`require` a file that ends in `.css`, then we will apply
408
+
This time when you run `webpack`, if you`require` a file that ends in `.css`, then we will apply
409
409
the `style` and `css` loaders to it, which adds the CSS to the bundle.
410
410
411
411
If we didn't have the loaders,
@@ -692,7 +692,7 @@ but I left it separate because I feel like it lengthens the tutorial for too tri
0 commit comments