From b343cf7a58621ff989308b15f482cc93572ae195 Mon Sep 17 00:00:00 2001 From: Bogdan Chadkin Date: Tue, 18 Jul 2017 17:25:28 +0300 Subject: [PATCH] Filter published files on npm (#5626) * Filter published files on npm For now not gzipped leaflet package is 23mb. There's weird 4mb file `.goutputstream-N6HL8X` and a lot other stuff which increases node_modules size. `files` field can fix this with specified whitelist. * Remove npmignore --- .npmignore | 10 ---------- package.json | 5 +++++ 2 files changed, 5 insertions(+), 10 deletions(-) delete mode 100644 .npmignore diff --git a/.npmignore b/.npmignore deleted file mode 100644 index 2549faa6..00000000 --- a/.npmignore +++ /dev/null @@ -1,10 +0,0 @@ -node_modules -.DS_Store -tmp/**/* -.idea -.idea/**/* -*.iml -*.sublime-* -_site -coverage/ -dist/leaflet.zip diff --git a/package.json b/package.json index 96008411..04a1dbd1 100644 --- a/package.json +++ b/package.json @@ -30,6 +30,11 @@ }, "main": "dist/leaflet-src.js", "style": "dist/leaflet.css", + "files": [ + "dist", + "src", + "!dist/leaflet.zip" + ], "scripts": { "test-jake": "jake test", "test": "jake test",