This commit is contained in:
Kevin Jahns
2019-03-30 11:09:37 +01:00
commit 9208e699e2
6 changed files with 498 additions and 0 deletions

18
rollup.config.js Normal file
View File

@@ -0,0 +1,18 @@
export default {
input: './src/y-websocket.js',
external: id => /^(funlib|yjs|y-protocols)/.test(id),
output: [{
name: 'y-websocket',
file: 'dist/y-websocket.js',
format: 'cjs',
sourcemap: true,
paths: path => {
if (/^funlib\//.test(path)) {
return `lib0/dist${path.slice(6)}`
} else if (/^y\-protocols\//.test(path)) {
return `y-protocols/dist${path.slice(11)}`
}
return path
}
}]
}