1 Star 0 Fork 0

yjh/react-movie

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
webpack.config.js 843 Bytes
一键复制 编辑 原始数据 按行查看 历史
yjh 提交于 2021-06-07 19:54 +08:00 . 完成电影列表路由页面设置
const path = require('path')
const htmlWebpackPlugin = require('html-webpack-plugin')
module.exports = {
entry: path.join(__dirname, './src/main.js'),
output: {
path: path.join(__dirname, './dist'),
filename: 'bundle.js'
},
plugins: [ // 插件
new htmlWebpackPlugin({
template: path.join(__dirname, './src/index.html'),
filename: 'index.html'
})
],
module: {
rules: [
{ test: /\.css$/, use: ['style-loader', 'css-loader'] }, // 如果想要启用 CSS 模块化,可以为 css-loader 添加 modules 参数即可
{ test: /\.scss$/, use: ['style-loader', 'css-loader?modules&localIdentName=[name]_[local]-[hash:5]', 'sass-loader'] },
{ test: /\.(png|gif|bmp|jpg)$/, use: 'url-loader?limit=5000' },
{ test: /\.jsx?$/, use: 'babel-loader', exclude: /node_modules/ }
]
}
}
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
JavaScript
1
https://gitee.com/yu-jianhang/react-movie.git
git@gitee.com:yu-jianhang/react-movie.git
yu-jianhang
react-movie
react-movie
master

搜索帮助