diff --git a/source/posts/2015/2015-01-15-how-to-use-webpack-with-rails.md b/source/posts/2015/2015-01-15-how-to-use-webpack-with-rails.md index 7121e30..d4d98b8 100644 --- a/source/posts/2015/2015-01-15-how-to-use-webpack-with-rails.md +++ b/source/posts/2015/2015-01-15-how-to-use-webpack-with-rails.md @@ -352,9 +352,9 @@ Now your 'virtual' source files will appear under the `domain > assets` director We can use a loader to automatically transpile modules written in CoffeeScript or similar. As with the `expose` loader (explained above), this can be done inside the `require` statement, but it's far nicer to add this loader to the webpack config so we can then require CoffeeScript modules as though they were ordinary JS. -First, install and add the `coffee-loader` module to your `package.json`, like this: +First, install and add the `coffee-script` and `coffee-loader` modules to your `package.json`, like this: - $ npm install coffee-loader@0.7.2 --save-dev + $ npm install coffee-script coffee-loader@0.7.2 --save-dev Now, in our webpack config, update the `config.resolve.extensions` list so we can require `.coffee` files without specifying an extension: