我有这种brunch-config.js,其中select2 @4.0.3作为依赖:
exports.config = {
npm: {
enabled: true,
globals: {
$: 'jquery',
jQuery: 'jquery'
}
},
files: {
javascripts: {
joinTo: {
"js/app.js": [
"node_modules/phoenix/priv/static/phoenix.js",
"node_modules/phoenix_html/priv/static/phoenix_html.js",
"node_modules/process/browser.js",
"node_modules/jquery/dist/jquery.js",
"node_modules/select2/dist/js/select2.js",
"js/app.js",
]
}
},
stylesheets: {
joinTo: {
"css/app.css": [
"node_modules/select2/dist/css/select.min.css",
"css/phoenix.css",
"css/app.scss"
]
}
},
templates: {
joinTo: "js/app.js"
}
},
conventions: {
assets: /^(static)/
},
paths: {
watched: ["static", "css", "js", "vendor"],
public: "../priv/static"
},
plugins: {
babel: {
ignore: [/vendor/]
}
},
modules: {
autoRequire: {
"js/app.js": ["js/app"]
},
}
};
据我所知,早午餐从我的stylesheets.joinTo中获取样式表,并在输出文件中将它们连接在一起,但输出文件app.css中缺少select2样式。