Last active
May 31, 2021 11:44
-
-
Save zilton7/dffde146ac9bad485c94c984aea58112 to your computer and use it in GitHub Desktop.
example-webpack.config.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const path = require('path'); | |
module.exports = { | |
mode: 'development', | |
entry: './src/index.js', | |
output: { | |
filename: 'main.js', | |
path: path.resolve(__dirname, './'), | |
}, | |
module: { | |
rules: [ | |
{ | |
test: /\.css$/, | |
use: ['style-loader', 'css-loader'], | |
}, | |
], | |
}, | |
devServer: { | |
contentBase: path.resolve(__dirname, 'dist'), | |
port: 3000, | |
}, | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment