2019-11-19 17:08:04 +01:00
|
|
|
const path = require("path")
|
|
|
|
|
|
|
|
const EsmWebpackPlugin = require("@purtuga/esm-webpack-plugin")
|
|
|
|
|
2020-08-21 14:47:09 +02:00
|
|
|
const clientFiles = [
|
2021-02-20 15:41:00 +01:00
|
|
|
'common-client-plugin.js',
|
2021-02-18 18:31:12 +01:00
|
|
|
'videowatch-client-plugin.js'
|
2020-08-21 14:47:09 +02:00
|
|
|
]
|
|
|
|
|
|
|
|
let config = clientFiles.map(f => ({
|
|
|
|
entry: "./client/" + f,
|
2019-11-19 17:08:04 +01:00
|
|
|
output: {
|
|
|
|
path: path.resolve(__dirname, "./dist"),
|
2020-08-21 14:47:09 +02:00
|
|
|
filename: "./" + f,
|
2019-11-19 17:08:04 +01:00
|
|
|
library: "script",
|
|
|
|
libraryTarget: "var"
|
|
|
|
},
|
2020-08-21 14:47:09 +02:00
|
|
|
plugins: [ new EsmWebpackPlugin() ]
|
|
|
|
}))
|
2019-11-19 17:08:04 +01:00
|
|
|
|
|
|
|
module.exports = config
|