@soleil-se/build-app
Version:
Script for building WebApps, RESTApps and Widgets with Svelte in Sitevision.
26 lines (24 loc) • 653 B
JavaScript
import { client, server } from '../rollup/index.js';
import copy from '../utils/copy.js';
import configFiles from '../utils/configFiles.js';
export default function config({ src, dest, cache, debug }) {
return [
copy({ src: [`${src}/index.html`, `${src}/config.css`], dest, deep: false }),
server({
input: `${src}/index.js`,
output: `${dest}/index.js`,
debug,
}),
client({
input: `${src}/config.js`,
output: `${dest}/config.js`,
globals: { jquery: 'jQuery' },
showSize: false,
hydratable: false,
cache,
debug,
format: 'iife',
}),
configFiles({ dest }),
];
}