Skip to content
Snippets Groups Projects
Commit 1c61a176 authored by Reiter, Christoph's avatar Reiter, Christoph :snake:
Browse files

showcase: port to babel output plugin

like everything else
parent 05eda8d3
No related branches found
No related tags found
No related merge requests found
Pipeline #16497 failed
...@@ -12,7 +12,7 @@ import license from 'rollup-plugin-license'; ...@@ -12,7 +12,7 @@ import license from 'rollup-plugin-license';
import del from 'rollup-plugin-delete'; import del from 'rollup-plugin-delete';
import md from 'rollup-plugin-md'; import md from 'rollup-plugin-md';
import emitEJS from 'rollup-plugin-emit-ejs' import emitEJS from 'rollup-plugin-emit-ejs'
import babel from '@rollup/plugin-babel' import {getBabelOutputPlugin} from '@rollup/plugin-babel';
import appConfig from './app.config.js'; import appConfig from './app.config.js';
import {generateTLSConfig, getBuildInfo, getPackagePath, getDistPath} from '../rollup.utils.js'; import {generateTLSConfig, getBuildInfo, getPackagePath, getDistPath} from '../rollup.utils.js';
...@@ -191,30 +191,19 @@ Dependencies: ...@@ -191,30 +191,19 @@ Dependencies:
{src: await getPackagePath('qr-scanner', 'qr-scanner-worker.*'), dest: 'dist/' + await getDistPath('@dbp-toolkit/qr-code-scanner')}, {src: await getPackagePath('qr-scanner', 'qr-scanner-worker.*'), dest: 'dist/' + await getDistPath('@dbp-toolkit/qr-code-scanner')},
], ],
}), }),
useBabel && babel({ useBabel && getBabelOutputPlugin({
include: [ compact: false,
'src/**', presets: [[
'node_modules/pdfjs-dist/**', // uses Promise.allSettled '@babel/preset-env', {
], loose: true,
babelHelpers: 'runtime', shippedProposals: true,
babelrc: false, bugfixes: true,
presets: [[ modules: false,
'@babel/preset-env', { targets: {
loose: true, esmodules: true
bugfixes: true, }
targets: {
esmodules: true
} }
} ]],
]],
plugins: [[
'@babel/plugin-transform-runtime', {
corejs: 3,
useESModules: true
}
],
'@babel/plugin-syntax-dynamic-import',
'@babel/plugin-syntax-import-meta']
}), }),
watch ? serve({ watch ? serve({
contentBase: '.', contentBase: '.',
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment