From bd271e3952671f10a372d64f21f72f0b1742acb1 Mon Sep 17 00:00:00 2001 From: Kevin Jahns Date: Fri, 2 Nov 2018 01:52:20 +0100 Subject: [PATCH] update publish process --- package.json | 7 +++---- rollup.browser.js | 19 ++----------------- 2 files changed, 5 insertions(+), 21 deletions(-) diff --git a/package.json b/package.json index b914f853..48cfbfa7 100644 --- a/package.json +++ b/package.json @@ -2,8 +2,7 @@ "name": "yjs", "version": "13.0.0-67", "description": "A framework for real-time p2p shared editing on any data", - "main": "./y.node.js", - "browser": "./y.js", + "main": "./build/node/index.js", "module": "./src/index.js", "scripts": { "test": "npm run lint", @@ -16,10 +15,10 @@ "postversion": "npm run dist" }, "files": [ - "y.*", "src/*", ".esdoc.json", - "docs/*" + "docs/*", + "build/*" ], "standard": { "ignore": [ diff --git a/rollup.browser.js b/rollup.browser.js index d5f6c137..0fa9b06a 100644 --- a/rollup.browser.js +++ b/rollup.browser.js @@ -5,11 +5,11 @@ import commonjs from 'rollup-plugin-commonjs' var pkg = require('./package.json') export default { - input: 'src/Y.dist.js', + input: 'src/index.js', name: 'Y', sourcemap: true, output: { - file: 'y.js', + file: 'build/umd/index.js', format: 'umd' }, plugins: [ @@ -20,21 +20,6 @@ export default { }), commonjs(), babel(), - uglify({ - mangle: { - except: ['YMap', 'Y', 'YArray', 'YText', 'YXmlHook', 'YXmlFragment', 'YXmlElement', 'YXmlEvent', 'YXmlText', 'YEvent', 'YArrayEvent', 'YMapEvent', 'Type', 'Delete', 'ItemJSON', 'ItemString', 'Item'] - }, - output: { - comments: function (node, comment) { - var text = comment.value - var type = comment.type - if (type === 'comment2') { - // multiline comment - return /@license/i.test(text) - } - } - } - }) ], banner: ` /**