reservations_display/webpack.config.js

50 lines
944 B
JavaScript
Raw Normal View History

const path = require('path');
module.exports = {
mode: 'development',
entry: './src/index.ts',
devServer: {
proxy: {
'/calendar': {
target: 'https://calendar.google.com',
changeOrigin: true,
},
},
},
2022-03-11 00:08:59 -05:00
devtool: 'source-map',
module: {
rules: [
{
test: /\.m?js$/,
exclude: /node_modules/,
loader: 'babel-loader',
},
{
test: /\.tsx?$/,
exclude: /node_modules/,
2022-03-10 23:38:38 -05:00
use: ['babel-loader', 'ts-loader'],
},
{
test: /\.css$/i,
2022-03-10 23:38:38 -05:00
use: ['style-loader', 'css-loader'],
},
{
test: /\/index.html$/i,
use: {
2022-03-10 23:38:38 -05:00
loader: 'file-loader',
options: {
name: '[name].[ext]',
2022-03-10 23:38:38 -05:00
},
},
},
],
},
resolve: {
extensions: ['.tsx', '.ts', '.js'],
},
output: {
path: path.resolve(__dirname, 'dist'),
filename: 'bundle.js',
},
};