2019-10-01 02:58:05 +03:00
|
|
|
const path = require("path");
|
|
|
|
const CopyPlugin = require("copy-webpack-plugin");
|
2019-04-28 11:38:30 +01:00
|
|
|
|
|
|
|
module.exports = {
|
2019-10-01 02:58:05 +03:00
|
|
|
context: path.resolve(__dirname, "src"),
|
|
|
|
entry: "./bundle.js",
|
2019-04-28 11:38:30 +01:00
|
|
|
resolve: {
|
|
|
|
modules: [
|
2019-10-01 02:58:05 +03:00
|
|
|
path.resolve(__dirname, "node_modules")
|
2019-04-28 11:38:30 +01:00
|
|
|
]
|
2019-05-25 00:28:06 -04:00
|
|
|
},
|
2019-10-01 02:58:05 +03:00
|
|
|
plugins: [
|
2019-09-27 10:52:15 -04:00
|
|
|
new CopyPlugin([
|
|
|
|
{
|
|
|
|
from: "**/*",
|
|
|
|
to: "."
|
|
|
|
},
|
|
|
|
{
|
|
|
|
from: "../node_modules/libass-wasm/dist/subtitles-octopus-worker.*",
|
|
|
|
to: "JavascriptSubtitlesOctopus",
|
|
|
|
transformPath(targetPath, absolutePath) {
|
|
|
|
return Promise.resolve(path.join("JavascriptSubtitlesOctopus", path.basename(targetPath)));
|
|
|
|
}
|
|
|
|
}
|
|
|
|
])
|
2019-10-01 02:58:05 +03:00
|
|
|
]
|
2019-05-22 15:18:17 -04:00
|
|
|
};
|