Abgabe Max Kupper
This commit is contained in:
@@ -0,0 +1,42 @@
|
||||
const path = require("path");
|
||||
|
||||
module.exports = {
|
||||
mode: "development",
|
||||
entry: "./src/index.jsx",
|
||||
output: {
|
||||
filename: "bundle.js",
|
||||
path: path.resolve(__dirname, "dist"),
|
||||
},
|
||||
devServer: {
|
||||
static: {
|
||||
directory: path.join(__dirname, "dist"),
|
||||
},
|
||||
hot: true,
|
||||
port: 4000,
|
||||
},
|
||||
resolve: {
|
||||
extensions: [".js", ".jsx"],
|
||||
},
|
||||
module: {
|
||||
rules: [
|
||||
{
|
||||
test: /\.jsx?$/,
|
||||
loader: "builtin:swc-loader",
|
||||
options: {
|
||||
jsc: {
|
||||
parser: {
|
||||
syntax: "ecmascript",
|
||||
jsx: true
|
||||
},
|
||||
transform: {
|
||||
react: {
|
||||
runtime: "automatic", // Für JSX ohne import React
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
exclude: /node_modules/,
|
||||
}
|
||||
],
|
||||
},
|
||||
};
|
||||
Reference in New Issue
Block a user