annotate config/webpack/environment.js @ 481:88fd5722fcb3

Update defaults
author nanaya <me@nanaya.pro>
date Sun, 28 Nov 2021 19:45:05 +0900
parents 68231013b01b
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
468
802dcd44188e Now with webpacker
nanaya <me@nanaya.pro>
parents:
diff changeset
1 const { environment } = require('@rails/webpacker')
802dcd44188e Now with webpacker
nanaya <me@nanaya.pro>
parents:
diff changeset
2 const coffee = require('./loaders/coffee')
802dcd44188e Now with webpacker
nanaya <me@nanaya.pro>
parents:
diff changeset
3
802dcd44188e Now with webpacker
nanaya <me@nanaya.pro>
parents:
diff changeset
4 const webpack = require('webpack')
802dcd44188e Now with webpacker
nanaya <me@nanaya.pro>
parents:
diff changeset
5 environment.plugins.append('Provide',
802dcd44188e Now with webpacker
nanaya <me@nanaya.pro>
parents:
diff changeset
6 new webpack.ProvidePlugin({
802dcd44188e Now with webpacker
nanaya <me@nanaya.pro>
parents:
diff changeset
7 $: 'jquery',
802dcd44188e Now with webpacker
nanaya <me@nanaya.pro>
parents:
diff changeset
8 })
802dcd44188e Now with webpacker
nanaya <me@nanaya.pro>
parents:
diff changeset
9 )
802dcd44188e Now with webpacker
nanaya <me@nanaya.pro>
parents:
diff changeset
10
802dcd44188e Now with webpacker
nanaya <me@nanaya.pro>
parents:
diff changeset
11 environment.loaders.prepend('coffee', coffee)
802dcd44188e Now with webpacker
nanaya <me@nanaya.pro>
parents:
diff changeset
12 module.exports = environment