browser-extension/webpack.config.js
PRavaga 16f88631e2
webpack setup
Signed-off-by: PRavaga <trueravaga@gmail.com>
2023-04-13 19:12:22 +02:00

33 lines
746 B
JavaScript

const path = require("path");
const { merge } = require("webpack-merge");
const common = require("./webpack.common.js");
const appConfig = {
entry: "./src/index.js",
output: {
path: path.resolve(__dirname, "build"),
filename: "static/js/app.bundle.js",
},
};
const backgroundConfig = {
entry: "./src/background/background.js",
output: {
path: path.resolve(__dirname, "build/static/js"),
filename: "background.bundle.js",
},
};
const contentConfig = {
entry: "./src/content/content.js",
output: {
path: path.resolve(__dirname, "build/static/js"),
filename: "content.bundle.js",
},
};
module.exports = [
merge(common, appConfig),
merge(common, backgroundConfig),
merge(common, contentConfig),
];