mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
restore Assets
This commit is contained in:
parent
79d92c01da
commit
109d5bf32c
1 changed files with 34 additions and 0 deletions
|
@ -5,6 +5,24 @@ const packageConfig = require('./package.json');
|
||||||
const WorkboxPlugin = require('workbox-webpack-plugin');
|
const WorkboxPlugin = require('workbox-webpack-plugin');
|
||||||
const HtmlWebpackPlugin = require('html-webpack-plugin');
|
const HtmlWebpackPlugin = require('html-webpack-plugin');
|
||||||
|
|
||||||
|
const Assets = [
|
||||||
|
'alameda/alameda.js',
|
||||||
|
'native-promise-only/npo.js',
|
||||||
|
'libarchive.js/dist/worker-bundle.js',
|
||||||
|
'libass-wasm/dist/js/subtitles-octopus-worker.js',
|
||||||
|
'libass-wasm/dist/js/subtitles-octopus-worker.data',
|
||||||
|
'libass-wasm/dist/js/subtitles-octopus-worker.wasm',
|
||||||
|
'libass-wasm/dist/js/subtitles-octopus-worker-legacy.js',
|
||||||
|
'libass-wasm/dist/js/subtitles-octopus-worker-legacy.data',
|
||||||
|
'libass-wasm/dist/js/subtitles-octopus-worker-legacy.js.mem',
|
||||||
|
'pdfjs-dist/build/pdf.worker.js'
|
||||||
|
];
|
||||||
|
|
||||||
|
const LibarchiveWasm = [
|
||||||
|
'libarchive.js/dist/wasm-gen/libarchive.js',
|
||||||
|
'libarchive.js/dist/wasm-gen/libarchive.wasm'
|
||||||
|
];
|
||||||
|
|
||||||
module.exports = {
|
module.exports = {
|
||||||
context: path.resolve(__dirname, 'src'),
|
context: path.resolve(__dirname, 'src'),
|
||||||
target: 'web',
|
target: 'web',
|
||||||
|
@ -39,6 +57,22 @@ module.exports = {
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}),
|
}),
|
||||||
|
new CopyPlugin({
|
||||||
|
patterns: Assets.map(asset => {
|
||||||
|
return {
|
||||||
|
from: path.resolve(__dirname, `./node_modules/${asset}`),
|
||||||
|
to: path.resolve(__dirname, './dist/libraries')
|
||||||
|
};
|
||||||
|
})
|
||||||
|
}),
|
||||||
|
new CopyPlugin({
|
||||||
|
patterns: LibarchiveWasm.map(asset => {
|
||||||
|
return {
|
||||||
|
from: path.resolve(__dirname, `./node_modules/${asset}`),
|
||||||
|
to: path.resolve(__dirname, './dist/libraries/wasm-gen')
|
||||||
|
};
|
||||||
|
})
|
||||||
|
}),
|
||||||
new WorkboxPlugin.InjectManifest({
|
new WorkboxPlugin.InjectManifest({
|
||||||
swSrc: path.resolve(__dirname, 'src/serviceworker.js'),
|
swSrc: path.resolve(__dirname, 'src/serviceworker.js'),
|
||||||
swDest: 'serviceworker.js'
|
swDest: 'serviceworker.js'
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue