Generate a bundle from a Pear application entrypoint
Per bare-bundle bundles.
import bundle from 'pear-bundle'
const opts = {
cache = false,
prebuilds: 'path/to/prebuilds',
entry: '/boot.js',
builtins = []
}
const packed = await bundle(opts)
console.log(packed.bundle) // bundle buffer
console.log(packed.prebuilds) // prebuilds Map
All options are per pear-pack options (except opts.target),
and with opts.cache.
opts.cacheSet to true to cache the bundle on system disk instead of generating each time.
Apache-2.0