fix imports in esm bundle

This commit is contained in:
Kevin Jahns 2020-02-12 10:52:51 +01:00
parent 45df311dd7
commit 18bb2d0719

View File

@ -57,13 +57,7 @@ export default [{
name: 'Y', name: 'Y',
file: 'dist/yjs.mjs', file: 'dist/yjs.mjs',
format: 'esm', format: 'esm',
sourcemap: true, sourcemap: true
paths: path => {
if (/^lib0\//.test(path)) {
return `lib0/dist/${path.slice(5, -3)}.cjs`
}
return path
}
}, },
external: id => /^lib0\//.test(id) external: id => /^lib0\//.test(id)
}, { }, {