main
1# Note: You must restart bin/webpack-dev-server for changes to take effect
2
3default: &default
4 source_path: app/javascript
5 source_entry_path: packs
6 public_root_path: public
7 public_output_path: packs
8 cache_path: tmp/cache/webpacker
9 check_yarn_integrity: false
10 webpack_compile_output: false
11
12 # Additional paths webpack should lookup modules
13 # ['app/assets', 'engine/foo/app/assets']
14 resolved_paths: []
15
16 # Reload manifest.json on all requests so we reload latest compiled packs
17 cache_manifest: false
18
19 # Extract and emit a css file
20 extract_css: true
21
22 static_assets_extensions:
23 - .jpg
24 - .jpeg
25 - .png
26 - .gif
27 - .tiff
28 - .ico
29 - .svg
30 - .eot
31 - .otf
32 - .ttf
33 - .woff
34 - .woff2
35
36 extensions:
37 - .mjs
38 - .js
39 - .sass
40 - .scss
41 - .css
42 - .module.sass
43 - .module.scss
44 - .module.css
45 - .png
46 - .svg
47 - .gif
48 - .jpeg
49 - .jpg
50
51development:
52 <<: *default
53 compile: true
54
55 # Verifies that correct packages and versions are installed by inspecting package.json, yarn.lock, and node_modules
56 check_yarn_integrity: true
57
58 # Reference: https://webpack.js.org/configuration/dev-server/
59 dev_server:
60 https: false
61 host: localhost
62 port: 3035
63 public: localhost:3035
64 hmr: false
65 # Inline should be set to true if using HMR
66 inline: true
67 overlay: true
68 compress: true
69 disable_host_check: true
70 use_local_ip: false
71 quiet: false
72 headers:
73 'Access-Control-Allow-Origin': '*'
74 watch_options:
75 ignored: '**/node_modules/**'
76
77
78test:
79 <<: *default
80 compile: true
81
82 # Compile test packs to a separate directory
83 public_output_path: packs-test
84
85production:
86 <<: *default
87
88 # Production depends on precompilation of packs prior to booting for performance.
89 compile: false
90
91 # Extract and emit a css file
92 extract_css: true
93
94 # Cache manifest.json for performance
95 cache_manifest: true