webpack: fix source maps

Signed-off-by: Varun Patil <radialapps@gmail.com>
pull/689/merge
Varun Patil 2023-10-18 12:55:12 -07:00
parent 1bf9022756
commit 2c35f20eec
2 changed files with 1 additions and 8 deletions

View File

@ -7,7 +7,6 @@ mkdir -p /tmp/memories
cp -R appinfo l10n img js lib templates COPYING README.md CHANGELOG.md exiftest* composer* /tmp/memories cp -R appinfo l10n img js lib templates COPYING README.md CHANGELOG.md exiftest* composer* /tmp/memories
cd /tmp cd /tmp
rm -f memories/appinfo/screencap* memories/js/*.map
rm -rf memories.tar.gz rm -rf memories.tar.gz
cd memories cd memories

View File

@ -15,7 +15,7 @@ console.info('Building', appName, appVersion, '\n');
module.exports = { module.exports = {
target: 'web', target: 'web',
mode: buildMode, mode: buildMode,
devtool: isDev ? 'cheap-source-map' : false, devtool: 'source-map',
cache: isDev, cache: isDev,
entry: { entry: {
@ -107,12 +107,6 @@ module.exports = {
includeAliases: ['stream', 'process'], // webdav includeAliases: ['stream', 'process'], // webdav
}), }),
// Configure source map public path
new webpack.SourceMapDevToolPlugin({
filename: '[file].map',
publicPath: path.join('/apps/', process.env.npm_package_name, '/js/'),
}),
// Bundle service worker // Bundle service worker
new WorkboxPlugin.InjectManifest({ new WorkboxPlugin.InjectManifest({
swSrc: path.resolve(path.join('src', 'service-worker.js')), swSrc: path.resolve(path.join('src', 'service-worker.js')),