Skip to content

Commit f0383de

Browse files
committed
configure webpacker builder to extract css into separate file
#343 (comment)
1 parent d9c2f83 commit f0383de

File tree

3 files changed

+6
-1
lines changed

3 files changed

+6
-1
lines changed

app/javascript/matestack-ui-core/index.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ import matestackEventHub from '../../../app/concepts/matestack/ui/core/js/event-
77
import componentMixin from '../../../app/concepts/matestack/ui/core/component/component'
88
import matestackUiCore from '../../../app/concepts/matestack/ui/core/js/core'
99

10+
import styles from './styles/index.css'
11+
1012
const MatestackUiCore = {
1113
Vue,
1214
Vuex,
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
body {
2+
background: blue;
3+
}

builder/config/webpacker.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ default: &default
1717
cache_manifest: false
1818

1919
# Extract and emit a css file
20-
extract_css: false
20+
extract_css: true
2121

2222
static_assets_extensions:
2323
- .jpg

0 commit comments

Comments
 (0)