现在是在 pack/pack 下有个 app.css 这个文件里@import "bootstrap/dist/css/bootstrap.min.css"; 然后 webpack-dev-server 报错是 ERROR in ./app/frontend/packs/css/application.css Module build failed: ModuleNotFoundError: Module not found: Error: Can't resolve '../fonts/glyphicons-halflings-regular.eot' in '/Users/jesse/WorkBench/my611230/app/frontend/packs/css'
然后我看了下 loaders 目录下面有个叫做 assets 文件有在用 file-loader 处理一些字体文件的啊? const { env, publicPath } = require('../configuration.js')
module.exports = { test: /.(jpg|jpeg|png|gif|svg|eot|ttf|woff|woff2)$/i, use: [{ loader: 'file-loader', options: { publicPath, name: env.NODE_ENV === 'production' ? '[name]-[hash].[ext]' : '[name].[ext]' } }] } 是这个文件 assets 文件 options 里面需要格外配置一些东西吗?