dragonfly_chrome_headless 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (228) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +10 -0
  3. data/.travis.yml +12 -0
  4. data/Gemfile +4 -0
  5. data/README.md +53 -0
  6. data/Rakefile +10 -0
  7. data/bin/console +14 -0
  8. data/bin/setup +8 -0
  9. data/dragonfly_chrome_headless.gemspec +27 -0
  10. data/lib/dragonfly_chrome_headless.rb +9 -0
  11. data/lib/dragonfly_chrome_headless/plugin.rb +17 -0
  12. data/lib/dragonfly_chrome_headless/processors/rasterize.rb +33 -0
  13. data/lib/dragonfly_chrome_headless/version.rb +3 -0
  14. data/node_modules/.bin/chrome-remote-interface +1 -0
  15. data/node_modules/.bin/mkdirp +1 -0
  16. data/node_modules/.bin/rimraf +1 -0
  17. data/node_modules/@types/core-js/LICENSE +21 -0
  18. data/node_modules/@types/core-js/README.md +16 -0
  19. data/node_modules/@types/core-js/index.d.ts +2452 -0
  20. data/node_modules/@types/core-js/package.json +85 -0
  21. data/node_modules/@types/mkdirp/README.md +18 -0
  22. data/node_modules/@types/mkdirp/index.d.ts +14 -0
  23. data/node_modules/@types/mkdirp/package.json +77 -0
  24. data/node_modules/@types/mkdirp/types-metadata.json +25 -0
  25. data/node_modules/@types/node/README.md +16 -0
  26. data/node_modules/@types/node/index.d.ts +4132 -0
  27. data/node_modules/@types/node/package.json +84 -0
  28. data/node_modules/balanced-match/.npmignore +5 -0
  29. data/node_modules/balanced-match/LICENSE.md +21 -0
  30. data/node_modules/balanced-match/README.md +91 -0
  31. data/node_modules/balanced-match/index.js +59 -0
  32. data/node_modules/balanced-match/package.json +112 -0
  33. data/node_modules/brace-expansion/README.md +123 -0
  34. data/node_modules/brace-expansion/index.js +201 -0
  35. data/node_modules/brace-expansion/package.json +114 -0
  36. data/node_modules/chrome-launcher/.clang-format +6 -0
  37. data/node_modules/chrome-launcher/.npmignore +11 -0
  38. data/node_modules/chrome-launcher/README.md +123 -0
  39. data/node_modules/chrome-launcher/ask.js +32 -0
  40. data/node_modules/chrome-launcher/ask.ts +35 -0
  41. data/node_modules/chrome-launcher/chrome-finder.js +157 -0
  42. data/node_modules/chrome-launcher/chrome-finder.ts +186 -0
  43. data/node_modules/chrome-launcher/chrome-launcher.js +245 -0
  44. data/node_modules/chrome-launcher/chrome-launcher.ts +312 -0
  45. data/node_modules/chrome-launcher/compiled-check.js +14 -0
  46. data/node_modules/chrome-launcher/flags.js +27 -0
  47. data/node_modules/chrome-launcher/flags.ts +26 -0
  48. data/node_modules/chrome-launcher/index.js +7 -0
  49. data/node_modules/chrome-launcher/index.ts +1 -0
  50. data/node_modules/chrome-launcher/manual-chrome-launcher.js +30 -0
  51. data/node_modules/chrome-launcher/package.json +116 -0
  52. data/node_modules/chrome-launcher/random-port.js +24 -0
  53. data/node_modules/chrome-launcher/random-port.ts +23 -0
  54. data/node_modules/chrome-launcher/tsconfig.json +19 -0
  55. data/node_modules/chrome-launcher/utils.js +52 -0
  56. data/node_modules/chrome-launcher/utils.ts +44 -0
  57. data/node_modules/chrome-launcher/yarn.lock +1486 -0
  58. data/node_modules/chrome-remote-interface/LICENSE +18 -0
  59. data/node_modules/chrome-remote-interface/README.md +849 -0
  60. data/node_modules/chrome-remote-interface/bin/client.js +337 -0
  61. data/node_modules/chrome-remote-interface/chrome-remote-interface.js +11 -0
  62. data/node_modules/chrome-remote-interface/index.js +39 -0
  63. data/node_modules/chrome-remote-interface/lib/api.js +84 -0
  64. data/node_modules/chrome-remote-interface/lib/chrome.js +307 -0
  65. data/node_modules/chrome-remote-interface/lib/defaults.js +4 -0
  66. data/node_modules/chrome-remote-interface/lib/devtools.js +245 -0
  67. data/node_modules/chrome-remote-interface/lib/external-request.js +28 -0
  68. data/node_modules/chrome-remote-interface/lib/protocol.json +13780 -0
  69. data/node_modules/chrome-remote-interface/lib/websocket-wrapper.js +32 -0
  70. data/node_modules/chrome-remote-interface/package.json +128 -0
  71. data/node_modules/chrome-remote-interface/webpack.config.js +55 -0
  72. data/node_modules/commander/Readme.md +195 -0
  73. data/node_modules/commander/index.js +851 -0
  74. data/node_modules/commander/package.json +92 -0
  75. data/node_modules/concat-map/.travis.yml +4 -0
  76. data/node_modules/concat-map/LICENSE +18 -0
  77. data/node_modules/concat-map/README.markdown +62 -0
  78. data/node_modules/concat-map/example/map.js +6 -0
  79. data/node_modules/concat-map/index.js +13 -0
  80. data/node_modules/concat-map/package.json +117 -0
  81. data/node_modules/concat-map/test/map.js +39 -0
  82. data/node_modules/debug/.coveralls.yml +1 -0
  83. data/node_modules/debug/.eslintrc +11 -0
  84. data/node_modules/debug/.npmignore +9 -0
  85. data/node_modules/debug/.travis.yml +14 -0
  86. data/node_modules/debug/CHANGELOG.md +357 -0
  87. data/node_modules/debug/LICENSE +19 -0
  88. data/node_modules/debug/Makefile +50 -0
  89. data/node_modules/debug/Readme.md +312 -0
  90. data/node_modules/debug/component.json +19 -0
  91. data/node_modules/debug/karma.conf.js +70 -0
  92. data/node_modules/debug/node.js +1 -0
  93. data/node_modules/debug/package.json +124 -0
  94. data/node_modules/debug/src/browser.js +185 -0
  95. data/node_modules/debug/src/debug.js +202 -0
  96. data/node_modules/debug/src/index.js +10 -0
  97. data/node_modules/debug/src/node.js +246 -0
  98. data/node_modules/fs.realpath/LICENSE +43 -0
  99. data/node_modules/fs.realpath/README.md +33 -0
  100. data/node_modules/fs.realpath/index.js +66 -0
  101. data/node_modules/fs.realpath/old.js +303 -0
  102. data/node_modules/fs.realpath/package.json +94 -0
  103. data/node_modules/glob/LICENSE +15 -0
  104. data/node_modules/glob/README.md +368 -0
  105. data/node_modules/glob/changelog.md +67 -0
  106. data/node_modules/glob/common.js +240 -0
  107. data/node_modules/glob/glob.js +790 -0
  108. data/node_modules/glob/package.json +112 -0
  109. data/node_modules/glob/sync.js +486 -0
  110. data/node_modules/html-pdf-chrome/.npmignore +9 -0
  111. data/node_modules/html-pdf-chrome/LICENSE +21 -0
  112. data/node_modules/html-pdf-chrome/README.md +165 -0
  113. data/node_modules/html-pdf-chrome/lib/src/ChromePrintOptions.d.ts +87 -0
  114. data/node_modules/html-pdf-chrome/lib/src/ChromePrintOptions.js +4 -0
  115. data/node_modules/html-pdf-chrome/lib/src/ChromePrintOptions.js.map +1 -0
  116. data/node_modules/html-pdf-chrome/lib/src/CompletionTrigger.d.ts +120 -0
  117. data/node_modules/html-pdf-chrome/lib/src/CompletionTrigger.js +206 -0
  118. data/node_modules/html-pdf-chrome/lib/src/CompletionTrigger.js.map +1 -0
  119. data/node_modules/html-pdf-chrome/lib/src/CreateResult.d.ts +70 -0
  120. data/node_modules/html-pdf-chrome/lib/src/CreateResult.js +98 -0
  121. data/node_modules/html-pdf-chrome/lib/src/CreateResult.js.map +1 -0
  122. data/node_modules/html-pdf-chrome/lib/src/index.d.ts +72 -0
  123. data/node_modules/html-pdf-chrome/lib/src/index.js +123 -0
  124. data/node_modules/html-pdf-chrome/lib/src/index.js.map +1 -0
  125. data/node_modules/html-pdf-chrome/package.json +133 -0
  126. data/node_modules/html-pdf-chrome/src/ChromePrintOptions.ts +99 -0
  127. data/node_modules/html-pdf-chrome/src/CompletionTrigger.ts +201 -0
  128. data/node_modules/html-pdf-chrome/src/CreateResult.ts +100 -0
  129. data/node_modules/html-pdf-chrome/src/index.ts +179 -0
  130. data/node_modules/inflight/LICENSE +15 -0
  131. data/node_modules/inflight/README.md +37 -0
  132. data/node_modules/inflight/inflight.js +54 -0
  133. data/node_modules/inflight/package.json +105 -0
  134. data/node_modules/inherits/LICENSE +16 -0
  135. data/node_modules/inherits/README.md +42 -0
  136. data/node_modules/inherits/inherits.js +7 -0
  137. data/node_modules/inherits/inherits_browser.js +23 -0
  138. data/node_modules/inherits/package.json +97 -0
  139. data/node_modules/lighthouse-logger/README.md +4 -0
  140. data/node_modules/lighthouse-logger/index.js +212 -0
  141. data/node_modules/lighthouse-logger/package.json +69 -0
  142. data/node_modules/lighthouse-logger/yarn.lock +13 -0
  143. data/node_modules/minimatch/LICENSE +15 -0
  144. data/node_modules/minimatch/README.md +209 -0
  145. data/node_modules/minimatch/minimatch.js +923 -0
  146. data/node_modules/minimatch/package.json +99 -0
  147. data/node_modules/minimist/.travis.yml +4 -0
  148. data/node_modules/minimist/LICENSE +18 -0
  149. data/node_modules/minimist/example/parse.js +2 -0
  150. data/node_modules/minimist/index.js +187 -0
  151. data/node_modules/minimist/package.json +101 -0
  152. data/node_modules/minimist/readme.markdown +73 -0
  153. data/node_modules/minimist/test/dash.js +24 -0
  154. data/node_modules/minimist/test/default_bool.js +20 -0
  155. data/node_modules/minimist/test/dotted.js +16 -0
  156. data/node_modules/minimist/test/long.js +31 -0
  157. data/node_modules/minimist/test/parse.js +318 -0
  158. data/node_modules/minimist/test/parse_modified.js +9 -0
  159. data/node_modules/minimist/test/short.js +67 -0
  160. data/node_modules/minimist/test/whitespace.js +8 -0
  161. data/node_modules/mkdirp/.travis.yml +8 -0
  162. data/node_modules/mkdirp/LICENSE +21 -0
  163. data/node_modules/mkdirp/bin/cmd.js +33 -0
  164. data/node_modules/mkdirp/bin/usage.txt +12 -0
  165. data/node_modules/mkdirp/examples/pow.js +6 -0
  166. data/node_modules/mkdirp/index.js +98 -0
  167. data/node_modules/mkdirp/package.json +93 -0
  168. data/node_modules/mkdirp/readme.markdown +100 -0
  169. data/node_modules/mkdirp/test/chmod.js +41 -0
  170. data/node_modules/mkdirp/test/clobber.js +38 -0
  171. data/node_modules/mkdirp/test/mkdirp.js +28 -0
  172. data/node_modules/mkdirp/test/opts_fs.js +29 -0
  173. data/node_modules/mkdirp/test/opts_fs_sync.js +27 -0
  174. data/node_modules/mkdirp/test/perm.js +32 -0
  175. data/node_modules/mkdirp/test/perm_sync.js +36 -0
  176. data/node_modules/mkdirp/test/race.js +37 -0
  177. data/node_modules/mkdirp/test/rel.js +32 -0
  178. data/node_modules/mkdirp/test/return.js +25 -0
  179. data/node_modules/mkdirp/test/return_sync.js +24 -0
  180. data/node_modules/mkdirp/test/root.js +19 -0
  181. data/node_modules/mkdirp/test/sync.js +32 -0
  182. data/node_modules/mkdirp/test/umask.js +28 -0
  183. data/node_modules/mkdirp/test/umask_sync.js +32 -0
  184. data/node_modules/ms/README.md +51 -0
  185. data/node_modules/ms/index.js +152 -0
  186. data/node_modules/ms/license.md +21 -0
  187. data/node_modules/ms/package.json +109 -0
  188. data/node_modules/once/LICENSE +15 -0
  189. data/node_modules/once/README.md +79 -0
  190. data/node_modules/once/once.js +42 -0
  191. data/node_modules/once/package.json +101 -0
  192. data/node_modules/path-is-absolute/index.js +20 -0
  193. data/node_modules/path-is-absolute/license +21 -0
  194. data/node_modules/path-is-absolute/package.json +111 -0
  195. data/node_modules/path-is-absolute/readme.md +59 -0
  196. data/node_modules/rimraf/LICENSE +15 -0
  197. data/node_modules/rimraf/README.md +101 -0
  198. data/node_modules/rimraf/bin.js +50 -0
  199. data/node_modules/rimraf/package.json +99 -0
  200. data/node_modules/rimraf/rimraf.js +363 -0
  201. data/node_modules/ultron/LICENSE +22 -0
  202. data/node_modules/ultron/index.js +138 -0
  203. data/node_modules/ultron/package.json +112 -0
  204. data/node_modules/wrappy/LICENSE +15 -0
  205. data/node_modules/wrappy/README.md +36 -0
  206. data/node_modules/wrappy/package.json +97 -0
  207. data/node_modules/wrappy/wrappy.js +33 -0
  208. data/node_modules/ws/LICENSE +21 -0
  209. data/node_modules/ws/README.md +259 -0
  210. data/node_modules/ws/SECURITY.md +33 -0
  211. data/node_modules/ws/index.js +15 -0
  212. data/node_modules/ws/lib/BufferUtil.fallback.js +56 -0
  213. data/node_modules/ws/lib/BufferUtil.js +15 -0
  214. data/node_modules/ws/lib/ErrorCodes.js +28 -0
  215. data/node_modules/ws/lib/EventTarget.js +158 -0
  216. data/node_modules/ws/lib/Extensions.js +69 -0
  217. data/node_modules/ws/lib/PerMessageDeflate.js +339 -0
  218. data/node_modules/ws/lib/Receiver.js +520 -0
  219. data/node_modules/ws/lib/Sender.js +438 -0
  220. data/node_modules/ws/lib/Validation.fallback.js +9 -0
  221. data/node_modules/ws/lib/Validation.js +17 -0
  222. data/node_modules/ws/lib/WebSocket.js +705 -0
  223. data/node_modules/ws/lib/WebSocketServer.js +336 -0
  224. data/node_modules/ws/package.json +122 -0
  225. data/package.json +26 -0
  226. data/samples/sample.html +13 -0
  227. data/script/rasterize.js +18 -0
  228. metadata +325 -0
@@ -0,0 +1,92 @@
1
+ {
2
+ "_args": [
3
+ [
4
+ {
5
+ "raw": "commander@2.1.x",
6
+ "scope": null,
7
+ "escapedName": "commander",
8
+ "name": "commander",
9
+ "rawSpec": "2.1.x",
10
+ "spec": ">=2.1.0 <2.2.0",
11
+ "type": "range"
12
+ },
13
+ "/Users/tomascelizna/Devel/dragonfly_chrome_headless/node_modules/chrome-remote-interface"
14
+ ]
15
+ ],
16
+ "_from": "commander@>=2.1.0 <2.2.0",
17
+ "_id": "commander@2.1.0",
18
+ "_inCache": true,
19
+ "_location": "/commander",
20
+ "_npmUser": {
21
+ "name": "tjholowaychuk",
22
+ "email": "tj@vision-media.ca"
23
+ },
24
+ "_npmVersion": "1.3.14",
25
+ "_phantomChildren": {},
26
+ "_requested": {
27
+ "raw": "commander@2.1.x",
28
+ "scope": null,
29
+ "escapedName": "commander",
30
+ "name": "commander",
31
+ "rawSpec": "2.1.x",
32
+ "spec": ">=2.1.0 <2.2.0",
33
+ "type": "range"
34
+ },
35
+ "_requiredBy": [
36
+ "/chrome-remote-interface"
37
+ ],
38
+ "_resolved": "https://registry.npmjs.org/commander/-/commander-2.1.0.tgz",
39
+ "_shasum": "d121bbae860d9992a3d517ba96f56588e47c6781",
40
+ "_shrinkwrap": null,
41
+ "_spec": "commander@2.1.x",
42
+ "_where": "/Users/tomascelizna/Devel/dragonfly_chrome_headless/node_modules/chrome-remote-interface",
43
+ "author": {
44
+ "name": "TJ Holowaychuk",
45
+ "email": "tj@vision-media.ca"
46
+ },
47
+ "bugs": {
48
+ "url": "https://github.com/visionmedia/commander.js/issues"
49
+ },
50
+ "dependencies": {},
51
+ "description": "the complete solution for node.js command-line programs",
52
+ "devDependencies": {
53
+ "should": ">= 0.0.1"
54
+ },
55
+ "directories": {},
56
+ "dist": {
57
+ "shasum": "d121bbae860d9992a3d517ba96f56588e47c6781",
58
+ "tarball": "https://registry.npmjs.org/commander/-/commander-2.1.0.tgz"
59
+ },
60
+ "engines": {
61
+ "node": ">= 0.6.x"
62
+ },
63
+ "files": [
64
+ "index.js"
65
+ ],
66
+ "homepage": "https://github.com/visionmedia/commander.js",
67
+ "keywords": [
68
+ "command",
69
+ "option",
70
+ "parser",
71
+ "prompt",
72
+ "stdin"
73
+ ],
74
+ "main": "index",
75
+ "maintainers": [
76
+ {
77
+ "name": "tjholowaychuk",
78
+ "email": "tj@vision-media.ca"
79
+ }
80
+ ],
81
+ "name": "commander",
82
+ "optionalDependencies": {},
83
+ "readme": "ERROR: No README data found!",
84
+ "repository": {
85
+ "type": "git",
86
+ "url": "git+https://github.com/visionmedia/commander.js.git"
87
+ },
88
+ "scripts": {
89
+ "test": "make test"
90
+ },
91
+ "version": "2.1.0"
92
+ }
@@ -0,0 +1,4 @@
1
+ language: node_js
2
+ node_js:
3
+ - 0.4
4
+ - 0.6
@@ -0,0 +1,18 @@
1
+ This software is released under the MIT license:
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining a copy of
4
+ this software and associated documentation files (the "Software"), to deal in
5
+ the Software without restriction, including without limitation the rights to
6
+ use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
7
+ the Software, and to permit persons to whom the Software is furnished to do so,
8
+ subject to the following conditions:
9
+
10
+ The above copyright notice and this permission notice shall be included in all
11
+ copies or substantial portions of the Software.
12
+
13
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
15
+ FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
16
+ COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
17
+ IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
18
+ CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
@@ -0,0 +1,62 @@
1
+ concat-map
2
+ ==========
3
+
4
+ Concatenative mapdashery.
5
+
6
+ [![browser support](http://ci.testling.com/substack/node-concat-map.png)](http://ci.testling.com/substack/node-concat-map)
7
+
8
+ [![build status](https://secure.travis-ci.org/substack/node-concat-map.png)](http://travis-ci.org/substack/node-concat-map)
9
+
10
+ example
11
+ =======
12
+
13
+ ``` js
14
+ var concatMap = require('concat-map');
15
+ var xs = [ 1, 2, 3, 4, 5, 6 ];
16
+ var ys = concatMap(xs, function (x) {
17
+ return x % 2 ? [ x - 0.1, x, x + 0.1 ] : [];
18
+ });
19
+ console.dir(ys);
20
+ ```
21
+
22
+ ***
23
+
24
+ ```
25
+ [ 0.9, 1, 1.1, 2.9, 3, 3.1, 4.9, 5, 5.1 ]
26
+ ```
27
+
28
+ methods
29
+ =======
30
+
31
+ ``` js
32
+ var concatMap = require('concat-map')
33
+ ```
34
+
35
+ concatMap(xs, fn)
36
+ -----------------
37
+
38
+ Return an array of concatenated elements by calling `fn(x, i)` for each element
39
+ `x` and each index `i` in the array `xs`.
40
+
41
+ When `fn(x, i)` returns an array, its result will be concatenated with the
42
+ result array. If `fn(x, i)` returns anything else, that value will be pushed
43
+ onto the end of the result array.
44
+
45
+ install
46
+ =======
47
+
48
+ With [npm](http://npmjs.org) do:
49
+
50
+ ```
51
+ npm install concat-map
52
+ ```
53
+
54
+ license
55
+ =======
56
+
57
+ MIT
58
+
59
+ notes
60
+ =====
61
+
62
+ This module was written while sitting high above the ground in a tree.
@@ -0,0 +1,6 @@
1
+ var concatMap = require('../');
2
+ var xs = [ 1, 2, 3, 4, 5, 6 ];
3
+ var ys = concatMap(xs, function (x) {
4
+ return x % 2 ? [ x - 0.1, x, x + 0.1 ] : [];
5
+ });
6
+ console.dir(ys);
@@ -0,0 +1,13 @@
1
+ module.exports = function (xs, fn) {
2
+ var res = [];
3
+ for (var i = 0; i < xs.length; i++) {
4
+ var x = fn(xs[i], i);
5
+ if (isArray(x)) res.push.apply(res, x);
6
+ else res.push(x);
7
+ }
8
+ return res;
9
+ };
10
+
11
+ var isArray = Array.isArray || function (xs) {
12
+ return Object.prototype.toString.call(xs) === '[object Array]';
13
+ };
@@ -0,0 +1,117 @@
1
+ {
2
+ "_args": [
3
+ [
4
+ {
5
+ "raw": "concat-map@0.0.1",
6
+ "scope": null,
7
+ "escapedName": "concat-map",
8
+ "name": "concat-map",
9
+ "rawSpec": "0.0.1",
10
+ "spec": "0.0.1",
11
+ "type": "version"
12
+ },
13
+ "/Users/tomascelizna/Devel/dragonfly_chrome_headless/node_modules/brace-expansion"
14
+ ]
15
+ ],
16
+ "_from": "concat-map@0.0.1",
17
+ "_id": "concat-map@0.0.1",
18
+ "_inCache": true,
19
+ "_location": "/concat-map",
20
+ "_npmUser": {
21
+ "name": "substack",
22
+ "email": "mail@substack.net"
23
+ },
24
+ "_npmVersion": "1.3.21",
25
+ "_phantomChildren": {},
26
+ "_requested": {
27
+ "raw": "concat-map@0.0.1",
28
+ "scope": null,
29
+ "escapedName": "concat-map",
30
+ "name": "concat-map",
31
+ "rawSpec": "0.0.1",
32
+ "spec": "0.0.1",
33
+ "type": "version"
34
+ },
35
+ "_requiredBy": [
36
+ "/brace-expansion"
37
+ ],
38
+ "_resolved": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz",
39
+ "_shasum": "d8a96bd77fd68df7793a73036a3ba0d5405d477b",
40
+ "_shrinkwrap": null,
41
+ "_spec": "concat-map@0.0.1",
42
+ "_where": "/Users/tomascelizna/Devel/dragonfly_chrome_headless/node_modules/brace-expansion",
43
+ "author": {
44
+ "name": "James Halliday",
45
+ "email": "mail@substack.net",
46
+ "url": "http://substack.net"
47
+ },
48
+ "bugs": {
49
+ "url": "https://github.com/substack/node-concat-map/issues"
50
+ },
51
+ "dependencies": {},
52
+ "description": "concatenative mapdashery",
53
+ "devDependencies": {
54
+ "tape": "~2.4.0"
55
+ },
56
+ "directories": {
57
+ "example": "example",
58
+ "test": "test"
59
+ },
60
+ "dist": {
61
+ "shasum": "d8a96bd77fd68df7793a73036a3ba0d5405d477b",
62
+ "tarball": "https://registry.npmjs.org/concat-map/-/concat-map-0.0.1.tgz"
63
+ },
64
+ "homepage": "https://github.com/substack/node-concat-map",
65
+ "keywords": [
66
+ "concat",
67
+ "concatMap",
68
+ "map",
69
+ "functional",
70
+ "higher-order"
71
+ ],
72
+ "license": "MIT",
73
+ "main": "index.js",
74
+ "maintainers": [
75
+ {
76
+ "name": "substack",
77
+ "email": "mail@substack.net"
78
+ }
79
+ ],
80
+ "name": "concat-map",
81
+ "optionalDependencies": {},
82
+ "readme": "ERROR: No README data found!",
83
+ "repository": {
84
+ "type": "git",
85
+ "url": "git://github.com/substack/node-concat-map.git"
86
+ },
87
+ "scripts": {
88
+ "test": "tape test/*.js"
89
+ },
90
+ "testling": {
91
+ "files": "test/*.js",
92
+ "browsers": {
93
+ "ie": [
94
+ 6,
95
+ 7,
96
+ 8,
97
+ 9
98
+ ],
99
+ "ff": [
100
+ 3.5,
101
+ 10,
102
+ 15
103
+ ],
104
+ "chrome": [
105
+ 10,
106
+ 22
107
+ ],
108
+ "safari": [
109
+ 5.1
110
+ ],
111
+ "opera": [
112
+ 12
113
+ ]
114
+ }
115
+ },
116
+ "version": "0.0.1"
117
+ }
@@ -0,0 +1,39 @@
1
+ var concatMap = require('../');
2
+ var test = require('tape');
3
+
4
+ test('empty or not', function (t) {
5
+ var xs = [ 1, 2, 3, 4, 5, 6 ];
6
+ var ixes = [];
7
+ var ys = concatMap(xs, function (x, ix) {
8
+ ixes.push(ix);
9
+ return x % 2 ? [ x - 0.1, x, x + 0.1 ] : [];
10
+ });
11
+ t.same(ys, [ 0.9, 1, 1.1, 2.9, 3, 3.1, 4.9, 5, 5.1 ]);
12
+ t.same(ixes, [ 0, 1, 2, 3, 4, 5 ]);
13
+ t.end();
14
+ });
15
+
16
+ test('always something', function (t) {
17
+ var xs = [ 'a', 'b', 'c', 'd' ];
18
+ var ys = concatMap(xs, function (x) {
19
+ return x === 'b' ? [ 'B', 'B', 'B' ] : [ x ];
20
+ });
21
+ t.same(ys, [ 'a', 'B', 'B', 'B', 'c', 'd' ]);
22
+ t.end();
23
+ });
24
+
25
+ test('scalars', function (t) {
26
+ var xs = [ 'a', 'b', 'c', 'd' ];
27
+ var ys = concatMap(xs, function (x) {
28
+ return x === 'b' ? [ 'B', 'B', 'B' ] : x;
29
+ });
30
+ t.same(ys, [ 'a', 'B', 'B', 'B', 'c', 'd' ]);
31
+ t.end();
32
+ });
33
+
34
+ test('undefs', function (t) {
35
+ var xs = [ 'a', 'b', 'c', 'd' ];
36
+ var ys = concatMap(xs, function () {});
37
+ t.same(ys, [ undefined, undefined, undefined, undefined ]);
38
+ t.end();
39
+ });
@@ -0,0 +1 @@
1
+ repo_token: SIAeZjKYlHK74rbcFvNHMUzjRiMpflxve
@@ -0,0 +1,11 @@
1
+ {
2
+ "env": {
3
+ "browser": true,
4
+ "node": true
5
+ },
6
+ "rules": {
7
+ "no-console": 0,
8
+ "no-empty": [1, { "allowEmptyCatch": true }]
9
+ },
10
+ "extends": "eslint:recommended"
11
+ }
@@ -0,0 +1,9 @@
1
+ support
2
+ test
3
+ examples
4
+ example
5
+ *.sock
6
+ dist
7
+ yarn.lock
8
+ coverage
9
+ bower.json
@@ -0,0 +1,14 @@
1
+
2
+ language: node_js
3
+ node_js:
4
+ - "6"
5
+ - "5"
6
+ - "4"
7
+
8
+ install:
9
+ - make node_modules
10
+
11
+ script:
12
+ - make lint
13
+ - make test
14
+ - make coveralls
@@ -0,0 +1,357 @@
1
+
2
+ 2.6.8 / 2017-05-18
3
+ ==================
4
+
5
+ * Fix: Check for undefined on browser globals (#462, @marbemac)
6
+
7
+ 2.6.7 / 2017-05-16
8
+ ==================
9
+
10
+ * Fix: Update ms to 2.0.0 to fix regular expression denial of service vulnerability (#458, @hubdotcom)
11
+ * Fix: Inline extend function in node implementation (#452, @dougwilson)
12
+ * Docs: Fix typo (#455, @msasad)
13
+
14
+ 2.6.5 / 2017-04-27
15
+ ==================
16
+
17
+ * Fix: null reference check on window.documentElement.style.WebkitAppearance (#447, @thebigredgeek)
18
+ * Misc: clean up browser reference checks (#447, @thebigredgeek)
19
+ * Misc: add npm-debug.log to .gitignore (@thebigredgeek)
20
+
21
+
22
+ 2.6.4 / 2017-04-20
23
+ ==================
24
+
25
+ * Fix: bug that would occure if process.env.DEBUG is a non-string value. (#444, @LucianBuzzo)
26
+ * Chore: ignore bower.json in npm installations. (#437, @joaovieira)
27
+ * Misc: update "ms" to v0.7.3 (@tootallnate)
28
+
29
+ 2.6.3 / 2017-03-13
30
+ ==================
31
+
32
+ * Fix: Electron reference to `process.env.DEBUG` (#431, @paulcbetts)
33
+ * Docs: Changelog fix (@thebigredgeek)
34
+
35
+ 2.6.2 / 2017-03-10
36
+ ==================
37
+
38
+ * Fix: DEBUG_MAX_ARRAY_LENGTH (#420, @slavaGanzin)
39
+ * Docs: Add backers and sponsors from Open Collective (#422, @piamancini)
40
+ * Docs: Add Slackin invite badge (@tootallnate)
41
+
42
+ 2.6.1 / 2017-02-10
43
+ ==================
44
+
45
+ * Fix: Module's `export default` syntax fix for IE8 `Expected identifier` error
46
+ * Fix: Whitelist DEBUG_FD for values 1 and 2 only (#415, @pi0)
47
+ * Fix: IE8 "Expected identifier" error (#414, @vgoma)
48
+ * Fix: Namespaces would not disable once enabled (#409, @musikov)
49
+
50
+ 2.6.0 / 2016-12-28
51
+ ==================
52
+
53
+ * Fix: added better null pointer checks for browser useColors (@thebigredgeek)
54
+ * Improvement: removed explicit `window.debug` export (#404, @tootallnate)
55
+ * Improvement: deprecated `DEBUG_FD` environment variable (#405, @tootallnate)
56
+
57
+ 2.5.2 / 2016-12-25
58
+ ==================
59
+
60
+ * Fix: reference error on window within webworkers (#393, @KlausTrainer)
61
+ * Docs: fixed README typo (#391, @lurch)
62
+ * Docs: added notice about v3 api discussion (@thebigredgeek)
63
+
64
+ 2.5.1 / 2016-12-20
65
+ ==================
66
+
67
+ * Fix: babel-core compatibility
68
+
69
+ 2.5.0 / 2016-12-20
70
+ ==================
71
+
72
+ * Fix: wrong reference in bower file (@thebigredgeek)
73
+ * Fix: webworker compatibility (@thebigredgeek)
74
+ * Fix: output formatting issue (#388, @kribblo)
75
+ * Fix: babel-loader compatibility (#383, @escwald)
76
+ * Misc: removed built asset from repo and publications (@thebigredgeek)
77
+ * Misc: moved source files to /src (#378, @yamikuronue)
78
+ * Test: added karma integration and replaced babel with browserify for browser tests (#378, @yamikuronue)
79
+ * Test: coveralls integration (#378, @yamikuronue)
80
+ * Docs: simplified language in the opening paragraph (#373, @yamikuronue)
81
+
82
+ 2.4.5 / 2016-12-17
83
+ ==================
84
+
85
+ * Fix: `navigator` undefined in Rhino (#376, @jochenberger)
86
+ * Fix: custom log function (#379, @hsiliev)
87
+ * Improvement: bit of cleanup + linting fixes (@thebigredgeek)
88
+ * Improvement: rm non-maintainted `dist/` dir (#375, @freewil)
89
+ * Docs: simplified language in the opening paragraph. (#373, @yamikuronue)
90
+
91
+ 2.4.4 / 2016-12-14
92
+ ==================
93
+
94
+ * Fix: work around debug being loaded in preload scripts for electron (#368, @paulcbetts)
95
+
96
+ 2.4.3 / 2016-12-14
97
+ ==================
98
+
99
+ * Fix: navigation.userAgent error for react native (#364, @escwald)
100
+
101
+ 2.4.2 / 2016-12-14
102
+ ==================
103
+
104
+ * Fix: browser colors (#367, @tootallnate)
105
+ * Misc: travis ci integration (@thebigredgeek)
106
+ * Misc: added linting and testing boilerplate with sanity check (@thebigredgeek)
107
+
108
+ 2.4.1 / 2016-12-13
109
+ ==================
110
+
111
+ * Fix: typo that broke the package (#356)
112
+
113
+ 2.4.0 / 2016-12-13
114
+ ==================
115
+
116
+ * Fix: bower.json references unbuilt src entry point (#342, @justmatt)
117
+ * Fix: revert "handle regex special characters" (@tootallnate)
118
+ * Feature: configurable util.inspect()`options for NodeJS (#327, @tootallnate)
119
+ * Feature: %O`(big O) pretty-prints objects (#322, @tootallnate)
120
+ * Improvement: allow colors in workers (#335, @botverse)
121
+ * Improvement: use same color for same namespace. (#338, @lchenay)
122
+
123
+ 2.3.3 / 2016-11-09
124
+ ==================
125
+
126
+ * Fix: Catch `JSON.stringify()` errors (#195, Jovan Alleyne)
127
+ * Fix: Returning `localStorage` saved values (#331, Levi Thomason)
128
+ * Improvement: Don't create an empty object when no `process` (Nathan Rajlich)
129
+
130
+ 2.3.2 / 2016-11-09
131
+ ==================
132
+
133
+ * Fix: be super-safe in index.js as well (@TooTallNate)
134
+ * Fix: should check whether process exists (Tom Newby)
135
+
136
+ 2.3.1 / 2016-11-09
137
+ ==================
138
+
139
+ * Fix: Added electron compatibility (#324, @paulcbetts)
140
+ * Improvement: Added performance optimizations (@tootallnate)
141
+ * Readme: Corrected PowerShell environment variable example (#252, @gimre)
142
+ * Misc: Removed yarn lock file from source control (#321, @fengmk2)
143
+
144
+ 2.3.0 / 2016-11-07
145
+ ==================
146
+
147
+ * Fix: Consistent placement of ms diff at end of output (#215, @gorangajic)
148
+ * Fix: Escaping of regex special characters in namespace strings (#250, @zacronos)
149
+ * Fix: Fixed bug causing crash on react-native (#282, @vkarpov15)
150
+ * Feature: Enabled ES6+ compatible import via default export (#212 @bucaran)
151
+ * Feature: Added %O formatter to reflect Chrome's console.log capability (#279, @oncletom)
152
+ * Package: Update "ms" to 0.7.2 (#315, @DevSide)
153
+ * Package: removed superfluous version property from bower.json (#207 @kkirsche)
154
+ * Readme: fix USE_COLORS to DEBUG_COLORS
155
+ * Readme: Doc fixes for format string sugar (#269, @mlucool)
156
+ * Readme: Updated docs for DEBUG_FD and DEBUG_COLORS environment variables (#232, @mattlyons0)
157
+ * Readme: doc fixes for PowerShell (#271 #243, @exoticknight @unreadable)
158
+ * Readme: better docs for browser support (#224, @matthewmueller)
159
+ * Tooling: Added yarn integration for development (#317, @thebigredgeek)
160
+ * Misc: Renamed History.md to CHANGELOG.md (@thebigredgeek)
161
+ * Misc: Added license file (#226 #274, @CantemoInternal @sdaitzman)
162
+ * Misc: Updated contributors (@thebigredgeek)
163
+
164
+ 2.2.0 / 2015-05-09
165
+ ==================
166
+
167
+ * package: update "ms" to v0.7.1 (#202, @dougwilson)
168
+ * README: add logging to file example (#193, @DanielOchoa)
169
+ * README: fixed a typo (#191, @amir-s)
170
+ * browser: expose `storage` (#190, @stephenmathieson)
171
+ * Makefile: add a `distclean` target (#189, @stephenmathieson)
172
+
173
+ 2.1.3 / 2015-03-13
174
+ ==================
175
+
176
+ * Updated stdout/stderr example (#186)
177
+ * Updated example/stdout.js to match debug current behaviour
178
+ * Renamed example/stderr.js to stdout.js
179
+ * Update Readme.md (#184)
180
+ * replace high intensity foreground color for bold (#182, #183)
181
+
182
+ 2.1.2 / 2015-03-01
183
+ ==================
184
+
185
+ * dist: recompile
186
+ * update "ms" to v0.7.0
187
+ * package: update "browserify" to v9.0.3
188
+ * component: fix "ms.js" repo location
189
+ * changed bower package name
190
+ * updated documentation about using debug in a browser
191
+ * fix: security error on safari (#167, #168, @yields)
192
+
193
+ 2.1.1 / 2014-12-29
194
+ ==================
195
+
196
+ * browser: use `typeof` to check for `console` existence
197
+ * browser: check for `console.log` truthiness (fix IE 8/9)
198
+ * browser: add support for Chrome apps
199
+ * Readme: added Windows usage remarks
200
+ * Add `bower.json` to properly support bower install
201
+
202
+ 2.1.0 / 2014-10-15
203
+ ==================
204
+
205
+ * node: implement `DEBUG_FD` env variable support
206
+ * package: update "browserify" to v6.1.0
207
+ * package: add "license" field to package.json (#135, @panuhorsmalahti)
208
+
209
+ 2.0.0 / 2014-09-01
210
+ ==================
211
+
212
+ * package: update "browserify" to v5.11.0
213
+ * node: use stderr rather than stdout for logging (#29, @stephenmathieson)
214
+
215
+ 1.0.4 / 2014-07-15
216
+ ==================
217
+
218
+ * dist: recompile
219
+ * example: remove `console.info()` log usage
220
+ * example: add "Content-Type" UTF-8 header to browser example
221
+ * browser: place %c marker after the space character
222
+ * browser: reset the "content" color via `color: inherit`
223
+ * browser: add colors support for Firefox >= v31
224
+ * debug: prefer an instance `log()` function over the global one (#119)
225
+ * Readme: update documentation about styled console logs for FF v31 (#116, @wryk)
226
+
227
+ 1.0.3 / 2014-07-09
228
+ ==================
229
+
230
+ * Add support for multiple wildcards in namespaces (#122, @seegno)
231
+ * browser: fix lint
232
+
233
+ 1.0.2 / 2014-06-10
234
+ ==================
235
+
236
+ * browser: update color palette (#113, @gscottolson)
237
+ * common: make console logging function configurable (#108, @timoxley)
238
+ * node: fix %o colors on old node <= 0.8.x
239
+ * Makefile: find node path using shell/which (#109, @timoxley)
240
+
241
+ 1.0.1 / 2014-06-06
242
+ ==================
243
+
244
+ * browser: use `removeItem()` to clear localStorage
245
+ * browser, node: don't set DEBUG if namespaces is undefined (#107, @leedm777)
246
+ * package: add "contributors" section
247
+ * node: fix comment typo
248
+ * README: list authors
249
+
250
+ 1.0.0 / 2014-06-04
251
+ ==================
252
+
253
+ * make ms diff be global, not be scope
254
+ * debug: ignore empty strings in enable()
255
+ * node: make DEBUG_COLORS able to disable coloring
256
+ * *: export the `colors` array
257
+ * npmignore: don't publish the `dist` dir
258
+ * Makefile: refactor to use browserify
259
+ * package: add "browserify" as a dev dependency
260
+ * Readme: add Web Inspector Colors section
261
+ * node: reset terminal color for the debug content
262
+ * node: map "%o" to `util.inspect()`
263
+ * browser: map "%j" to `JSON.stringify()`
264
+ * debug: add custom "formatters"
265
+ * debug: use "ms" module for humanizing the diff
266
+ * Readme: add "bash" syntax highlighting
267
+ * browser: add Firebug color support
268
+ * browser: add colors for WebKit browsers
269
+ * node: apply log to `console`
270
+ * rewrite: abstract common logic for Node & browsers
271
+ * add .jshintrc file
272
+
273
+ 0.8.1 / 2014-04-14
274
+ ==================
275
+
276
+ * package: re-add the "component" section
277
+
278
+ 0.8.0 / 2014-03-30
279
+ ==================
280
+
281
+ * add `enable()` method for nodejs. Closes #27
282
+ * change from stderr to stdout
283
+ * remove unnecessary index.js file
284
+
285
+ 0.7.4 / 2013-11-13
286
+ ==================
287
+
288
+ * remove "browserify" key from package.json (fixes something in browserify)
289
+
290
+ 0.7.3 / 2013-10-30
291
+ ==================
292
+
293
+ * fix: catch localStorage security error when cookies are blocked (Chrome)
294
+ * add debug(err) support. Closes #46
295
+ * add .browser prop to package.json. Closes #42
296
+
297
+ 0.7.2 / 2013-02-06
298
+ ==================
299
+
300
+ * fix package.json
301
+ * fix: Mobile Safari (private mode) is broken with debug
302
+ * fix: Use unicode to send escape character to shell instead of octal to work with strict mode javascript
303
+
304
+ 0.7.1 / 2013-02-05
305
+ ==================
306
+
307
+ * add repository URL to package.json
308
+ * add DEBUG_COLORED to force colored output
309
+ * add browserify support
310
+ * fix component. Closes #24
311
+
312
+ 0.7.0 / 2012-05-04
313
+ ==================
314
+
315
+ * Added .component to package.json
316
+ * Added debug.component.js build
317
+
318
+ 0.6.0 / 2012-03-16
319
+ ==================
320
+
321
+ * Added support for "-" prefix in DEBUG [Vinay Pulim]
322
+ * Added `.enabled` flag to the node version [TooTallNate]
323
+
324
+ 0.5.0 / 2012-02-02
325
+ ==================
326
+
327
+ * Added: humanize diffs. Closes #8
328
+ * Added `debug.disable()` to the CS variant
329
+ * Removed padding. Closes #10
330
+ * Fixed: persist client-side variant again. Closes #9
331
+
332
+ 0.4.0 / 2012-02-01
333
+ ==================
334
+
335
+ * Added browser variant support for older browsers [TooTallNate]
336
+ * Added `debug.enable('project:*')` to browser variant [TooTallNate]
337
+ * Added padding to diff (moved it to the right)
338
+
339
+ 0.3.0 / 2012-01-26
340
+ ==================
341
+
342
+ * Added millisecond diff when isatty, otherwise UTC string
343
+
344
+ 0.2.0 / 2012-01-22
345
+ ==================
346
+
347
+ * Added wildcard support
348
+
349
+ 0.1.0 / 2011-12-02
350
+ ==================
351
+
352
+ * Added: remove colors unless stderr isatty [TooTallNate]
353
+
354
+ 0.0.1 / 2010-01-03
355
+ ==================
356
+
357
+ * Initial release