PracticeKea-UI/webpack.config.js

38 lines
894 B
JavaScript
Raw Normal View History

2025-10-27 14:46:51 +00:00
var HtmlWebpackPlugin = require('html-webpack-plugin');
const path = require('path');
module.exports = {
mode: 'development',
resolve: {
extensions: ['.js', '.jsx']
},
module: {
rules: [
{
test: /\.jsx?$/,
loader: 'babel-loader'
}
]
},
resolve: {
extensions: ['.js', '.jsx'],
alias: {
'@': path.resolve(__dirname, 'src/'),
}
},
plugins: [new HtmlWebpackPlugin({
template: './src/index.html'
})],
devServer: {
historyApiFallback: true,
contentBase:'./',
},
externals: {
// global app config object
config: JSON.stringify({
// apiUrl: 'http://localhost:4000'
//apiUrl: 'http://localhost:8010/proxy'
apiUrl: 'https://api.odiprojects.com'
})
}
}