mirror of
https://github.com/kremalicious/umami.git
synced 2024-11-15 17:55:08 +01:00
20 lines
475 B
JavaScript
20 lines
475 B
JavaScript
import buble from '@rollup/plugin-buble';
|
|
import replace from '@rollup/plugin-replace';
|
|
import { terser } from 'rollup-plugin-terser';
|
|
|
|
export default {
|
|
input: 'tracker/index.js',
|
|
output: {
|
|
file: 'public/umami.js',
|
|
format: 'iife',
|
|
},
|
|
plugins: [
|
|
replace({
|
|
'/api/collect': process.env.COLLECT_API_ENDPOINT || '/api/collect',
|
|
delimiters: ['', ''],
|
|
}),
|
|
buble({ objectAssign: true }),
|
|
terser({ compress: { evaluate: false } }),
|
|
],
|
|
};
|