1
0
mirror of synced 2024-11-22 21:36:04 +03:00
vue-formulario/build/rollup.iife.config.js

38 lines
1.1 KiB
JavaScript
Raw Normal View History

import resolve from '@rollup/plugin-node-resolve'
import commonjs from '@rollup/plugin-commonjs' // Convert CommonJS modules to ES6
import buble from '@rollup/plugin-buble' // Transpile/polyfill with reasonable browser support
import vue from 'rollup-plugin-vue' // Handle .vue SFC files
import internal from 'rollup-plugin-internal'
import { terser } from 'rollup-plugin-terser'
export default {
input: 'src/Formulate.js', // Path relative to package.json
output: {
name: 'VueFormulate',
2020-02-29 07:30:43 +03:00
exports: 'default',
format: 'iife',
globals: {
'is-plain-object': 'isPlainObject',
2020-02-28 19:19:44 +03:00
'nanoid/non-secure': 'nanoid',
'is-url': 'isUrl',
'@braid/vue-formulate-i18n': 'VueFormulateI18n'
}
},
plugins: [
resolve({
browser: true,
preferBuiltins: false
}),
commonjs(),
internal(['is-plain-object', 'nanoid/non-secure', 'is-url', '@braid/vue-formulate-i18n']),
vue({
css: true, // Dynamically inject css as a <style> tag
compileTemplate: true // Explicitly convert template to render function
}),
buble({
objectAssign: 'Object.assign'
}), // Transpile to ES5,
terser()
]
}