peertube-theme-nctv-dark/peertube-plugin-video-annotation/webpack.config.js

29 lines
572 B
JavaScript
Raw Normal View History

2020-08-21 12:46:25 +00:00
const path = require("path")
const webpack = require('webpack')
const EsmWebpackPlugin = require("@purtuga/esm-webpack-plugin")
const clientFiles = [
'embed-client-plugin.js',
'video-watch-client-plugin.js',
'video-edit-client-plugin.js'
]
let config = clientFiles.map(f => ({
entry: "./client/" + f,
output: {
path: path.resolve(__dirname, "./dist"),
filename: "./" + f,
library: "script",
libraryTarget: "var"
},
plugins: [
new EsmWebpackPlugin()
],
externals: {
'video.js': 'window.videojs'
}
}))
module.exports = config