Created
August 9, 2023 19:03
-
-
Save Davisonpro/b93567cc235204396596d0d94efde968 to your computer and use it in GitHub Desktop.
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 = (env, argv) => { | |
return { | |
mode: argv.mode, | |
entry: './app/index.js', | |
output: { | |
filename: 'bundle.js', | |
path: path.resolve(__dirname, 'dist'), | |
}, | |
module: { | |
rules: [ | |
{ | |
test: /\.(js|jsx)$/, | |
exclude: /node_modules/, | |
use: 'babel-loader', | |
}, | |
{ | |
test: /\.css$/, // Apply CSS loaders to .css files | |
use: ['style-loader', 'css-loader'], | |
}, | |
], | |
}, | |
resolve: { | |
extensions: ['.js', '.jsx'], | |
} | |
} | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment