Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/webtorrent/webtorrent.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFeross Aboukhadijeh <feross@feross.org>2019-08-07 04:39:32 +0300
committerFeross Aboukhadijeh <feross@feross.org>2019-08-07 04:39:32 +0300
commitadf42874d3596b4a684fac209498e71287558000 (patch)
tree59bffde4daf606383a2b73c22e954c2a15e6af07
parent5999a2ce087db0444f54b20414370ad298aa095c (diff)
add size-disc script to visualize bundle
-rw-r--r--package.json5
1 files changed, 4 insertions, 1 deletions
diff --git a/package.json b/package.json
index 4160fc9..acf6ee2 100644
--- a/package.json
+++ b/package.json
@@ -71,6 +71,7 @@
"babel-minify": "^0.5.0",
"bittorrent-tracker": "^9.4.0",
"browserify": "^16.2.3",
+ "disc": "^1.3.3",
"electron": "^6.0.0",
"finalhandler": "^1.0.0",
"network-address": "^1.1.0",
@@ -110,7 +111,9 @@
"scripts": {
"build": "browserify --plugin tinyify -s WebTorrent -e . | minify > webtorrent.min.js",
"build-debug": "browserify -s WebTorrent -e ./ > webtorrent.debug.js",
- "size": "npm run build && cat webtorrent.min.js | gzip | wc -c",
+ "size": "npm run size-js && npm run size-disc",
+ "size-js": "npm run build && cat webtorrent.min.js | gzip | wc -c",
+ "size-disc": "browserify --plugin tinyify --full-paths . | discify --open",
"test": "standard && npm run test-node && npm run test-browser",
"test-browser": "airtap -- test/*.js test/browser/*.js",
"test-browser-local": "airtap --local -- test/*.js test/browser/*.js",