es6-crawler-detect 3.3.0 → 4.0.0-beta.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (358) hide show
  1. package/.babelrc +1 -1
  2. package/.mocharc.json +5 -0
  3. package/README.md +1 -0
  4. package/dist/main.bundle.js +1 -1
  5. package/eslint.config.mjs +62 -0
  6. package/example/node/package.json +1 -1
  7. package/example/node/yarn.lock +222 -99
  8. package/package.json +30 -25
  9. package/src/index.js +20 -14
  10. package/src/index.ts +18 -0
  11. package/src/lib/crawler/crawlers.js +1399 -1403
  12. package/src/lib/crawler/crawlers.ts +1397 -0
  13. package/src/lib/crawler/exclusions.js +58 -62
  14. package/src/lib/crawler/exclusions.ts +56 -0
  15. package/src/lib/crawler/headers.js +6 -10
  16. package/src/lib/crawler/headers.ts +18 -0
  17. package/src/lib/crawler/provider.js +1 -10
  18. package/src/lib/crawler/provider.ts +3 -0
  19. package/src/lib/crawler.js +98 -130
  20. package/src/lib/crawler.ts +128 -0
  21. package/src/types.js +2 -0
  22. package/src/types.ts +15 -0
  23. package/test/lib/crawler.spec.js +149 -0
  24. package/test/lib/crawler.spec.ts +116 -0
  25. package/tsconfig.json +16 -0
  26. package/webpack.common.js +20 -20
  27. package/webpack.dev.js +7 -7
  28. package/webpack.prod.js +14 -14
  29. package/.eslintignore +0 -6
  30. package/.eslintrc.json +0 -30
  31. package/example/node/node_modules/.bin/mime +0 -15
  32. package/example/node/node_modules/.bin/mime.cmd +0 -7
  33. package/example/node/node_modules/.yarn-integrity +0 -67
  34. package/example/node/node_modules/accepts/HISTORY.md +0 -236
  35. package/example/node/node_modules/accepts/LICENSE +0 -23
  36. package/example/node/node_modules/accepts/README.md +0 -142
  37. package/example/node/node_modules/accepts/index.js +0 -238
  38. package/example/node/node_modules/accepts/package.json +0 -47
  39. package/example/node/node_modules/array-flatten/LICENSE +0 -21
  40. package/example/node/node_modules/array-flatten/README.md +0 -43
  41. package/example/node/node_modules/array-flatten/array-flatten.js +0 -64
  42. package/example/node/node_modules/array-flatten/package.json +0 -39
  43. package/example/node/node_modules/body-parser/HISTORY.md +0 -624
  44. package/example/node/node_modules/body-parser/LICENSE +0 -23
  45. package/example/node/node_modules/body-parser/README.md +0 -456
  46. package/example/node/node_modules/body-parser/index.js +0 -157
  47. package/example/node/node_modules/body-parser/lib/read.js +0 -181
  48. package/example/node/node_modules/body-parser/lib/types/json.js +0 -230
  49. package/example/node/node_modules/body-parser/lib/types/raw.js +0 -101
  50. package/example/node/node_modules/body-parser/lib/types/text.js +0 -121
  51. package/example/node/node_modules/body-parser/lib/types/urlencoded.js +0 -284
  52. package/example/node/node_modules/body-parser/package.json +0 -52
  53. package/example/node/node_modules/bytes/History.md +0 -92
  54. package/example/node/node_modules/bytes/LICENSE +0 -23
  55. package/example/node/node_modules/bytes/Readme.md +0 -152
  56. package/example/node/node_modules/bytes/index.js +0 -166
  57. package/example/node/node_modules/bytes/package.json +0 -42
  58. package/example/node/node_modules/content-disposition/HISTORY.md +0 -60
  59. package/example/node/node_modules/content-disposition/LICENSE +0 -22
  60. package/example/node/node_modules/content-disposition/README.md +0 -142
  61. package/example/node/node_modules/content-disposition/index.js +0 -458
  62. package/example/node/node_modules/content-disposition/package.json +0 -44
  63. package/example/node/node_modules/content-type/HISTORY.md +0 -24
  64. package/example/node/node_modules/content-type/LICENSE +0 -22
  65. package/example/node/node_modules/content-type/README.md +0 -92
  66. package/example/node/node_modules/content-type/index.js +0 -222
  67. package/example/node/node_modules/content-type/package.json +0 -40
  68. package/example/node/node_modules/cookie/HISTORY.md +0 -128
  69. package/example/node/node_modules/cookie/LICENSE +0 -24
  70. package/example/node/node_modules/cookie/README.md +0 -257
  71. package/example/node/node_modules/cookie/index.js +0 -202
  72. package/example/node/node_modules/cookie/package.json +0 -40
  73. package/example/node/node_modules/cookie-signature/History.md +0 -38
  74. package/example/node/node_modules/cookie-signature/Readme.md +0 -42
  75. package/example/node/node_modules/cookie-signature/index.js +0 -51
  76. package/example/node/node_modules/cookie-signature/package.json +0 -18
  77. package/example/node/node_modules/debug/.coveralls.yml +0 -1
  78. package/example/node/node_modules/debug/.eslintrc +0 -11
  79. package/example/node/node_modules/debug/.travis.yml +0 -14
  80. package/example/node/node_modules/debug/CHANGELOG.md +0 -362
  81. package/example/node/node_modules/debug/LICENSE +0 -19
  82. package/example/node/node_modules/debug/Makefile +0 -50
  83. package/example/node/node_modules/debug/README.md +0 -312
  84. package/example/node/node_modules/debug/component.json +0 -19
  85. package/example/node/node_modules/debug/karma.conf.js +0 -70
  86. package/example/node/node_modules/debug/node.js +0 -1
  87. package/example/node/node_modules/debug/package.json +0 -49
  88. package/example/node/node_modules/debug/src/browser.js +0 -185
  89. package/example/node/node_modules/debug/src/debug.js +0 -202
  90. package/example/node/node_modules/debug/src/index.js +0 -10
  91. package/example/node/node_modules/debug/src/inspector-log.js +0 -15
  92. package/example/node/node_modules/debug/src/node.js +0 -248
  93. package/example/node/node_modules/depd/History.md +0 -96
  94. package/example/node/node_modules/depd/LICENSE +0 -22
  95. package/example/node/node_modules/depd/Readme.md +0 -280
  96. package/example/node/node_modules/depd/index.js +0 -522
  97. package/example/node/node_modules/depd/lib/browser/index.js +0 -77
  98. package/example/node/node_modules/depd/lib/compat/callsite-tostring.js +0 -103
  99. package/example/node/node_modules/depd/lib/compat/event-listener-count.js +0 -22
  100. package/example/node/node_modules/depd/lib/compat/index.js +0 -79
  101. package/example/node/node_modules/depd/package.json +0 -41
  102. package/example/node/node_modules/destroy/LICENSE +0 -22
  103. package/example/node/node_modules/destroy/README.md +0 -60
  104. package/example/node/node_modules/destroy/index.js +0 -75
  105. package/example/node/node_modules/destroy/package.json +0 -37
  106. package/example/node/node_modules/ee-first/LICENSE +0 -22
  107. package/example/node/node_modules/ee-first/README.md +0 -80
  108. package/example/node/node_modules/ee-first/index.js +0 -95
  109. package/example/node/node_modules/ee-first/package.json +0 -29
  110. package/example/node/node_modules/encodeurl/HISTORY.md +0 -14
  111. package/example/node/node_modules/encodeurl/LICENSE +0 -22
  112. package/example/node/node_modules/encodeurl/README.md +0 -128
  113. package/example/node/node_modules/encodeurl/index.js +0 -60
  114. package/example/node/node_modules/encodeurl/package.json +0 -40
  115. package/example/node/node_modules/escape-html/LICENSE +0 -24
  116. package/example/node/node_modules/escape-html/Readme.md +0 -43
  117. package/example/node/node_modules/escape-html/index.js +0 -78
  118. package/example/node/node_modules/escape-html/package.json +0 -24
  119. package/example/node/node_modules/etag/HISTORY.md +0 -83
  120. package/example/node/node_modules/etag/LICENSE +0 -22
  121. package/example/node/node_modules/etag/README.md +0 -159
  122. package/example/node/node_modules/etag/index.js +0 -131
  123. package/example/node/node_modules/etag/package.json +0 -47
  124. package/example/node/node_modules/express/History.md +0 -3510
  125. package/example/node/node_modules/express/LICENSE +0 -24
  126. package/example/node/node_modules/express/Readme.md +0 -158
  127. package/example/node/node_modules/express/index.js +0 -11
  128. package/example/node/node_modules/express/lib/application.js +0 -644
  129. package/example/node/node_modules/express/lib/express.js +0 -116
  130. package/example/node/node_modules/express/lib/middleware/init.js +0 -43
  131. package/example/node/node_modules/express/lib/middleware/query.js +0 -47
  132. package/example/node/node_modules/express/lib/request.js +0 -525
  133. package/example/node/node_modules/express/lib/response.js +0 -1147
  134. package/example/node/node_modules/express/lib/router/index.js +0 -668
  135. package/example/node/node_modules/express/lib/router/layer.js +0 -181
  136. package/example/node/node_modules/express/lib/router/route.js +0 -216
  137. package/example/node/node_modules/express/lib/utils.js +0 -302
  138. package/example/node/node_modules/express/lib/view.js +0 -182
  139. package/example/node/node_modules/express/package.json +0 -99
  140. package/example/node/node_modules/finalhandler/HISTORY.md +0 -187
  141. package/example/node/node_modules/finalhandler/LICENSE +0 -22
  142. package/example/node/node_modules/finalhandler/README.md +0 -148
  143. package/example/node/node_modules/finalhandler/index.js +0 -331
  144. package/example/node/node_modules/finalhandler/package.json +0 -45
  145. package/example/node/node_modules/forwarded/HISTORY.md +0 -21
  146. package/example/node/node_modules/forwarded/LICENSE +0 -22
  147. package/example/node/node_modules/forwarded/README.md +0 -57
  148. package/example/node/node_modules/forwarded/index.js +0 -90
  149. package/example/node/node_modules/forwarded/package.json +0 -45
  150. package/example/node/node_modules/fresh/HISTORY.md +0 -70
  151. package/example/node/node_modules/fresh/LICENSE +0 -23
  152. package/example/node/node_modules/fresh/README.md +0 -119
  153. package/example/node/node_modules/fresh/index.js +0 -137
  154. package/example/node/node_modules/fresh/package.json +0 -46
  155. package/example/node/node_modules/http-errors/HISTORY.md +0 -165
  156. package/example/node/node_modules/http-errors/LICENSE +0 -23
  157. package/example/node/node_modules/http-errors/README.md +0 -169
  158. package/example/node/node_modules/http-errors/index.js +0 -299
  159. package/example/node/node_modules/http-errors/package.json +0 -49
  160. package/example/node/node_modules/iconv-lite/Changelog.md +0 -162
  161. package/example/node/node_modules/iconv-lite/LICENSE +0 -21
  162. package/example/node/node_modules/iconv-lite/README.md +0 -156
  163. package/example/node/node_modules/iconv-lite/encodings/dbcs-codec.js +0 -555
  164. package/example/node/node_modules/iconv-lite/encodings/dbcs-data.js +0 -176
  165. package/example/node/node_modules/iconv-lite/encodings/index.js +0 -22
  166. package/example/node/node_modules/iconv-lite/encodings/internal.js +0 -188
  167. package/example/node/node_modules/iconv-lite/encodings/sbcs-codec.js +0 -72
  168. package/example/node/node_modules/iconv-lite/encodings/sbcs-data-generated.js +0 -451
  169. package/example/node/node_modules/iconv-lite/encodings/sbcs-data.js +0 -174
  170. package/example/node/node_modules/iconv-lite/encodings/tables/big5-added.json +0 -122
  171. package/example/node/node_modules/iconv-lite/encodings/tables/cp936.json +0 -264
  172. package/example/node/node_modules/iconv-lite/encodings/tables/cp949.json +0 -273
  173. package/example/node/node_modules/iconv-lite/encodings/tables/cp950.json +0 -177
  174. package/example/node/node_modules/iconv-lite/encodings/tables/eucjp.json +0 -182
  175. package/example/node/node_modules/iconv-lite/encodings/tables/gb18030-ranges.json +0 -1
  176. package/example/node/node_modules/iconv-lite/encodings/tables/gbk-added.json +0 -55
  177. package/example/node/node_modules/iconv-lite/encodings/tables/shiftjis.json +0 -125
  178. package/example/node/node_modules/iconv-lite/encodings/utf16.js +0 -177
  179. package/example/node/node_modules/iconv-lite/encodings/utf7.js +0 -290
  180. package/example/node/node_modules/iconv-lite/lib/bom-handling.js +0 -52
  181. package/example/node/node_modules/iconv-lite/lib/extend-node.js +0 -217
  182. package/example/node/node_modules/iconv-lite/lib/index.d.ts +0 -24
  183. package/example/node/node_modules/iconv-lite/lib/index.js +0 -153
  184. package/example/node/node_modules/iconv-lite/lib/streams.js +0 -121
  185. package/example/node/node_modules/iconv-lite/package.json +0 -46
  186. package/example/node/node_modules/inherits/LICENSE +0 -16
  187. package/example/node/node_modules/inherits/README.md +0 -42
  188. package/example/node/node_modules/inherits/inherits.js +0 -9
  189. package/example/node/node_modules/inherits/inherits_browser.js +0 -27
  190. package/example/node/node_modules/inherits/package.json +0 -29
  191. package/example/node/node_modules/ipaddr.js/LICENSE +0 -19
  192. package/example/node/node_modules/ipaddr.js/README.md +0 -233
  193. package/example/node/node_modules/ipaddr.js/ipaddr.min.js +0 -1
  194. package/example/node/node_modules/ipaddr.js/lib/ipaddr.js +0 -673
  195. package/example/node/node_modules/ipaddr.js/lib/ipaddr.js.d.ts +0 -68
  196. package/example/node/node_modules/ipaddr.js/package.json +0 -35
  197. package/example/node/node_modules/media-typer/HISTORY.md +0 -22
  198. package/example/node/node_modules/media-typer/LICENSE +0 -22
  199. package/example/node/node_modules/media-typer/README.md +0 -81
  200. package/example/node/node_modules/media-typer/index.js +0 -270
  201. package/example/node/node_modules/media-typer/package.json +0 -26
  202. package/example/node/node_modules/merge-descriptors/HISTORY.md +0 -21
  203. package/example/node/node_modules/merge-descriptors/LICENSE +0 -23
  204. package/example/node/node_modules/merge-descriptors/README.md +0 -48
  205. package/example/node/node_modules/merge-descriptors/index.js +0 -60
  206. package/example/node/node_modules/merge-descriptors/package.json +0 -32
  207. package/example/node/node_modules/methods/HISTORY.md +0 -29
  208. package/example/node/node_modules/methods/LICENSE +0 -24
  209. package/example/node/node_modules/methods/README.md +0 -51
  210. package/example/node/node_modules/methods/index.js +0 -69
  211. package/example/node/node_modules/methods/package.json +0 -36
  212. package/example/node/node_modules/mime/CHANGELOG.md +0 -164
  213. package/example/node/node_modules/mime/LICENSE +0 -21
  214. package/example/node/node_modules/mime/README.md +0 -90
  215. package/example/node/node_modules/mime/cli.js +0 -8
  216. package/example/node/node_modules/mime/mime.js +0 -108
  217. package/example/node/node_modules/mime/package.json +0 -44
  218. package/example/node/node_modules/mime/src/build.js +0 -53
  219. package/example/node/node_modules/mime/src/test.js +0 -60
  220. package/example/node/node_modules/mime/types.json +0 -1
  221. package/example/node/node_modules/mime-db/HISTORY.md +0 -499
  222. package/example/node/node_modules/mime-db/LICENSE +0 -22
  223. package/example/node/node_modules/mime-db/README.md +0 -100
  224. package/example/node/node_modules/mime-db/db.json +0 -8471
  225. package/example/node/node_modules/mime-db/index.js +0 -11
  226. package/example/node/node_modules/mime-db/package.json +0 -59
  227. package/example/node/node_modules/mime-types/HISTORY.md +0 -388
  228. package/example/node/node_modules/mime-types/LICENSE +0 -23
  229. package/example/node/node_modules/mime-types/README.md +0 -113
  230. package/example/node/node_modules/mime-types/index.js +0 -188
  231. package/example/node/node_modules/mime-types/package.json +0 -44
  232. package/example/node/node_modules/ms/index.js +0 -152
  233. package/example/node/node_modules/ms/license.md +0 -21
  234. package/example/node/node_modules/ms/package.json +0 -37
  235. package/example/node/node_modules/ms/readme.md +0 -51
  236. package/example/node/node_modules/negotiator/HISTORY.md +0 -103
  237. package/example/node/node_modules/negotiator/LICENSE +0 -24
  238. package/example/node/node_modules/negotiator/README.md +0 -203
  239. package/example/node/node_modules/negotiator/index.js +0 -124
  240. package/example/node/node_modules/negotiator/lib/charset.js +0 -169
  241. package/example/node/node_modules/negotiator/lib/encoding.js +0 -184
  242. package/example/node/node_modules/negotiator/lib/language.js +0 -179
  243. package/example/node/node_modules/negotiator/lib/mediaType.js +0 -294
  244. package/example/node/node_modules/negotiator/package.json +0 -42
  245. package/example/node/node_modules/on-finished/HISTORY.md +0 -88
  246. package/example/node/node_modules/on-finished/LICENSE +0 -23
  247. package/example/node/node_modules/on-finished/README.md +0 -154
  248. package/example/node/node_modules/on-finished/index.js +0 -196
  249. package/example/node/node_modules/on-finished/package.json +0 -31
  250. package/example/node/node_modules/parseurl/HISTORY.md +0 -58
  251. package/example/node/node_modules/parseurl/LICENSE +0 -24
  252. package/example/node/node_modules/parseurl/README.md +0 -133
  253. package/example/node/node_modules/parseurl/index.js +0 -158
  254. package/example/node/node_modules/parseurl/package.json +0 -40
  255. package/example/node/node_modules/path-to-regexp/History.md +0 -36
  256. package/example/node/node_modules/path-to-regexp/LICENSE +0 -21
  257. package/example/node/node_modules/path-to-regexp/Readme.md +0 -35
  258. package/example/node/node_modules/path-to-regexp/index.js +0 -129
  259. package/example/node/node_modules/path-to-regexp/package.json +0 -30
  260. package/example/node/node_modules/proxy-addr/HISTORY.md +0 -161
  261. package/example/node/node_modules/proxy-addr/LICENSE +0 -22
  262. package/example/node/node_modules/proxy-addr/README.md +0 -139
  263. package/example/node/node_modules/proxy-addr/index.js +0 -327
  264. package/example/node/node_modules/proxy-addr/package.json +0 -47
  265. package/example/node/node_modules/qs/.editorconfig +0 -39
  266. package/example/node/node_modules/qs/.eslintignore +0 -2
  267. package/example/node/node_modules/qs/.eslintrc +0 -35
  268. package/example/node/node_modules/qs/.github/FUNDING.yml +0 -12
  269. package/example/node/node_modules/qs/.nycrc +0 -13
  270. package/example/node/node_modules/qs/CHANGELOG.md +0 -359
  271. package/example/node/node_modules/qs/LICENSE.md +0 -29
  272. package/example/node/node_modules/qs/README.md +0 -604
  273. package/example/node/node_modules/qs/dist/qs.js +0 -832
  274. package/example/node/node_modules/qs/lib/formats.js +0 -23
  275. package/example/node/node_modules/qs/lib/index.js +0 -11
  276. package/example/node/node_modules/qs/lib/parse.js +0 -257
  277. package/example/node/node_modules/qs/lib/stringify.js +0 -278
  278. package/example/node/node_modules/qs/lib/utils.js +0 -251
  279. package/example/node/node_modules/qs/package.json +0 -69
  280. package/example/node/node_modules/qs/test/parse.js +0 -772
  281. package/example/node/node_modules/qs/test/stringify.js +0 -793
  282. package/example/node/node_modules/qs/test/utils.js +0 -136
  283. package/example/node/node_modules/range-parser/HISTORY.md +0 -56
  284. package/example/node/node_modules/range-parser/LICENSE +0 -23
  285. package/example/node/node_modules/range-parser/README.md +0 -84
  286. package/example/node/node_modules/range-parser/index.js +0 -162
  287. package/example/node/node_modules/range-parser/package.json +0 -44
  288. package/example/node/node_modules/raw-body/HISTORY.md +0 -284
  289. package/example/node/node_modules/raw-body/LICENSE +0 -22
  290. package/example/node/node_modules/raw-body/README.md +0 -217
  291. package/example/node/node_modules/raw-body/index.d.ts +0 -87
  292. package/example/node/node_modules/raw-body/index.js +0 -286
  293. package/example/node/node_modules/raw-body/package.json +0 -48
  294. package/example/node/node_modules/safe-buffer/LICENSE +0 -21
  295. package/example/node/node_modules/safe-buffer/README.md +0 -584
  296. package/example/node/node_modules/safe-buffer/index.d.ts +0 -187
  297. package/example/node/node_modules/safe-buffer/index.js +0 -65
  298. package/example/node/node_modules/safe-buffer/package.json +0 -51
  299. package/example/node/node_modules/safer-buffer/LICENSE +0 -21
  300. package/example/node/node_modules/safer-buffer/Porting-Buffer.md +0 -268
  301. package/example/node/node_modules/safer-buffer/Readme.md +0 -156
  302. package/example/node/node_modules/safer-buffer/dangerous.js +0 -58
  303. package/example/node/node_modules/safer-buffer/package.json +0 -34
  304. package/example/node/node_modules/safer-buffer/safer.js +0 -77
  305. package/example/node/node_modules/safer-buffer/tests.js +0 -406
  306. package/example/node/node_modules/send/HISTORY.md +0 -506
  307. package/example/node/node_modules/send/LICENSE +0 -23
  308. package/example/node/node_modules/send/README.md +0 -327
  309. package/example/node/node_modules/send/index.js +0 -1133
  310. package/example/node/node_modules/send/node_modules/.bin/mime +0 -15
  311. package/example/node/node_modules/send/node_modules/.bin/mime.cmd +0 -7
  312. package/example/node/node_modules/send/node_modules/ms/index.js +0 -162
  313. package/example/node/node_modules/send/node_modules/ms/license.md +0 -21
  314. package/example/node/node_modules/send/node_modules/ms/package.json +0 -38
  315. package/example/node/node_modules/send/node_modules/ms/readme.md +0 -59
  316. package/example/node/node_modules/send/package.json +0 -61
  317. package/example/node/node_modules/serve-static/HISTORY.md +0 -459
  318. package/example/node/node_modules/serve-static/LICENSE +0 -25
  319. package/example/node/node_modules/serve-static/README.md +0 -257
  320. package/example/node/node_modules/serve-static/index.js +0 -210
  321. package/example/node/node_modules/serve-static/package.json +0 -42
  322. package/example/node/node_modules/setprototypeof/LICENSE +0 -13
  323. package/example/node/node_modules/setprototypeof/README.md +0 -31
  324. package/example/node/node_modules/setprototypeof/index.d.ts +0 -2
  325. package/example/node/node_modules/setprototypeof/index.js +0 -17
  326. package/example/node/node_modules/setprototypeof/package.json +0 -38
  327. package/example/node/node_modules/setprototypeof/test/index.js +0 -24
  328. package/example/node/node_modules/statuses/HISTORY.md +0 -65
  329. package/example/node/node_modules/statuses/LICENSE +0 -23
  330. package/example/node/node_modules/statuses/README.md +0 -127
  331. package/example/node/node_modules/statuses/codes.json +0 -66
  332. package/example/node/node_modules/statuses/index.js +0 -113
  333. package/example/node/node_modules/statuses/package.json +0 -48
  334. package/example/node/node_modules/toidentifier/HISTORY.md +0 -9
  335. package/example/node/node_modules/toidentifier/LICENSE +0 -21
  336. package/example/node/node_modules/toidentifier/README.md +0 -61
  337. package/example/node/node_modules/toidentifier/index.js +0 -32
  338. package/example/node/node_modules/toidentifier/package.json +0 -38
  339. package/example/node/node_modules/type-is/HISTORY.md +0 -259
  340. package/example/node/node_modules/type-is/LICENSE +0 -23
  341. package/example/node/node_modules/type-is/README.md +0 -170
  342. package/example/node/node_modules/type-is/index.js +0 -266
  343. package/example/node/node_modules/type-is/package.json +0 -45
  344. package/example/node/node_modules/unpipe/HISTORY.md +0 -4
  345. package/example/node/node_modules/unpipe/LICENSE +0 -22
  346. package/example/node/node_modules/unpipe/README.md +0 -43
  347. package/example/node/node_modules/unpipe/index.js +0 -69
  348. package/example/node/node_modules/unpipe/package.json +0 -27
  349. package/example/node/node_modules/utils-merge/LICENSE +0 -20
  350. package/example/node/node_modules/utils-merge/README.md +0 -34
  351. package/example/node/node_modules/utils-merge/index.js +0 -23
  352. package/example/node/node_modules/utils-merge/package.json +0 -40
  353. package/example/node/node_modules/vary/HISTORY.md +0 -39
  354. package/example/node/node_modules/vary/LICENSE +0 -22
  355. package/example/node/node_modules/vary/README.md +0 -101
  356. package/example/node/node_modules/vary/index.js +0 -149
  357. package/example/node/node_modules/vary/package.json +0 -43
  358. package/test/lib/crawler.test.js +0 -94
@@ -1,188 +0,0 @@
1
- /*!
2
- * mime-types
3
- * Copyright(c) 2014 Jonathan Ong
4
- * Copyright(c) 2015 Douglas Christopher Wilson
5
- * MIT Licensed
6
- */
7
-
8
- 'use strict'
9
-
10
- /**
11
- * Module dependencies.
12
- * @private
13
- */
14
-
15
- var db = require('mime-db')
16
- var extname = require('path').extname
17
-
18
- /**
19
- * Module variables.
20
- * @private
21
- */
22
-
23
- var EXTRACT_TYPE_REGEXP = /^\s*([^;\s]*)(?:;|\s|$)/
24
- var TEXT_TYPE_REGEXP = /^text\//i
25
-
26
- /**
27
- * Module exports.
28
- * @public
29
- */
30
-
31
- exports.charset = charset
32
- exports.charsets = { lookup: charset }
33
- exports.contentType = contentType
34
- exports.extension = extension
35
- exports.extensions = Object.create(null)
36
- exports.lookup = lookup
37
- exports.types = Object.create(null)
38
-
39
- // Populate the extensions/types maps
40
- populateMaps(exports.extensions, exports.types)
41
-
42
- /**
43
- * Get the default charset for a MIME type.
44
- *
45
- * @param {string} type
46
- * @return {boolean|string}
47
- */
48
-
49
- function charset (type) {
50
- if (!type || typeof type !== 'string') {
51
- return false
52
- }
53
-
54
- // TODO: use media-typer
55
- var match = EXTRACT_TYPE_REGEXP.exec(type)
56
- var mime = match && db[match[1].toLowerCase()]
57
-
58
- if (mime && mime.charset) {
59
- return mime.charset
60
- }
61
-
62
- // default text/* to utf-8
63
- if (match && TEXT_TYPE_REGEXP.test(match[1])) {
64
- return 'UTF-8'
65
- }
66
-
67
- return false
68
- }
69
-
70
- /**
71
- * Create a full Content-Type header given a MIME type or extension.
72
- *
73
- * @param {string} str
74
- * @return {boolean|string}
75
- */
76
-
77
- function contentType (str) {
78
- // TODO: should this even be in this module?
79
- if (!str || typeof str !== 'string') {
80
- return false
81
- }
82
-
83
- var mime = str.indexOf('/') === -1
84
- ? exports.lookup(str)
85
- : str
86
-
87
- if (!mime) {
88
- return false
89
- }
90
-
91
- // TODO: use content-type or other module
92
- if (mime.indexOf('charset') === -1) {
93
- var charset = exports.charset(mime)
94
- if (charset) mime += '; charset=' + charset.toLowerCase()
95
- }
96
-
97
- return mime
98
- }
99
-
100
- /**
101
- * Get the default extension for a MIME type.
102
- *
103
- * @param {string} type
104
- * @return {boolean|string}
105
- */
106
-
107
- function extension (type) {
108
- if (!type || typeof type !== 'string') {
109
- return false
110
- }
111
-
112
- // TODO: use media-typer
113
- var match = EXTRACT_TYPE_REGEXP.exec(type)
114
-
115
- // get extensions
116
- var exts = match && exports.extensions[match[1].toLowerCase()]
117
-
118
- if (!exts || !exts.length) {
119
- return false
120
- }
121
-
122
- return exts[0]
123
- }
124
-
125
- /**
126
- * Lookup the MIME type for a file path/extension.
127
- *
128
- * @param {string} path
129
- * @return {boolean|string}
130
- */
131
-
132
- function lookup (path) {
133
- if (!path || typeof path !== 'string') {
134
- return false
135
- }
136
-
137
- // get the extension ("ext" or ".ext" or full path)
138
- var extension = extname('x.' + path)
139
- .toLowerCase()
140
- .substr(1)
141
-
142
- if (!extension) {
143
- return false
144
- }
145
-
146
- return exports.types[extension] || false
147
- }
148
-
149
- /**
150
- * Populate the extensions and types maps.
151
- * @private
152
- */
153
-
154
- function populateMaps (extensions, types) {
155
- // source preference (least -> most)
156
- var preference = ['nginx', 'apache', undefined, 'iana']
157
-
158
- Object.keys(db).forEach(function forEachMimeType (type) {
159
- var mime = db[type]
160
- var exts = mime.extensions
161
-
162
- if (!exts || !exts.length) {
163
- return
164
- }
165
-
166
- // mime -> extensions
167
- extensions[type] = exts
168
-
169
- // extension -> mime
170
- for (var i = 0; i < exts.length; i++) {
171
- var extension = exts[i]
172
-
173
- if (types[extension]) {
174
- var from = preference.indexOf(db[types[extension]].source)
175
- var to = preference.indexOf(mime.source)
176
-
177
- if (types[extension] !== 'application/octet-stream' &&
178
- (from > to || (from === to && types[extension].substr(0, 12) === 'application/'))) {
179
- // skip the remapping
180
- continue
181
- }
182
- }
183
-
184
- // set the extension -> mime
185
- types[extension] = type
186
- }
187
- })
188
- }
@@ -1,44 +0,0 @@
1
- {
2
- "name": "mime-types",
3
- "description": "The ultimate javascript content-type utility.",
4
- "version": "2.1.34",
5
- "contributors": [
6
- "Douglas Christopher Wilson <doug@somethingdoug.com>",
7
- "Jeremiah Senkpiel <fishrock123@rocketmail.com> (https://searchbeam.jit.su)",
8
- "Jonathan Ong <me@jongleberry.com> (http://jongleberry.com)"
9
- ],
10
- "license": "MIT",
11
- "keywords": [
12
- "mime",
13
- "types"
14
- ],
15
- "repository": "jshttp/mime-types",
16
- "dependencies": {
17
- "mime-db": "1.51.0"
18
- },
19
- "devDependencies": {
20
- "eslint": "7.32.0",
21
- "eslint-config-standard": "14.1.1",
22
- "eslint-plugin-import": "2.25.2",
23
- "eslint-plugin-markdown": "2.2.1",
24
- "eslint-plugin-node": "11.1.0",
25
- "eslint-plugin-promise": "5.1.1",
26
- "eslint-plugin-standard": "4.1.0",
27
- "mocha": "9.1.3",
28
- "nyc": "15.1.0"
29
- },
30
- "files": [
31
- "HISTORY.md",
32
- "LICENSE",
33
- "index.js"
34
- ],
35
- "engines": {
36
- "node": ">= 0.6"
37
- },
38
- "scripts": {
39
- "lint": "eslint .",
40
- "test": "mocha --reporter spec test/test.js",
41
- "test-ci": "nyc --reporter=lcov --reporter=text npm test",
42
- "test-cov": "nyc --reporter=html --reporter=text npm test"
43
- }
44
- }
@@ -1,152 +0,0 @@
1
- /**
2
- * Helpers.
3
- */
4
-
5
- var s = 1000;
6
- var m = s * 60;
7
- var h = m * 60;
8
- var d = h * 24;
9
- var y = d * 365.25;
10
-
11
- /**
12
- * Parse or format the given `val`.
13
- *
14
- * Options:
15
- *
16
- * - `long` verbose formatting [false]
17
- *
18
- * @param {String|Number} val
19
- * @param {Object} [options]
20
- * @throws {Error} throw an error if val is not a non-empty string or a number
21
- * @return {String|Number}
22
- * @api public
23
- */
24
-
25
- module.exports = function(val, options) {
26
- options = options || {};
27
- var type = typeof val;
28
- if (type === 'string' && val.length > 0) {
29
- return parse(val);
30
- } else if (type === 'number' && isNaN(val) === false) {
31
- return options.long ? fmtLong(val) : fmtShort(val);
32
- }
33
- throw new Error(
34
- 'val is not a non-empty string or a valid number. val=' +
35
- JSON.stringify(val)
36
- );
37
- };
38
-
39
- /**
40
- * Parse the given `str` and return milliseconds.
41
- *
42
- * @param {String} str
43
- * @return {Number}
44
- * @api private
45
- */
46
-
47
- function parse(str) {
48
- str = String(str);
49
- if (str.length > 100) {
50
- return;
51
- }
52
- var match = /^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(
53
- str
54
- );
55
- if (!match) {
56
- return;
57
- }
58
- var n = parseFloat(match[1]);
59
- var type = (match[2] || 'ms').toLowerCase();
60
- switch (type) {
61
- case 'years':
62
- case 'year':
63
- case 'yrs':
64
- case 'yr':
65
- case 'y':
66
- return n * y;
67
- case 'days':
68
- case 'day':
69
- case 'd':
70
- return n * d;
71
- case 'hours':
72
- case 'hour':
73
- case 'hrs':
74
- case 'hr':
75
- case 'h':
76
- return n * h;
77
- case 'minutes':
78
- case 'minute':
79
- case 'mins':
80
- case 'min':
81
- case 'm':
82
- return n * m;
83
- case 'seconds':
84
- case 'second':
85
- case 'secs':
86
- case 'sec':
87
- case 's':
88
- return n * s;
89
- case 'milliseconds':
90
- case 'millisecond':
91
- case 'msecs':
92
- case 'msec':
93
- case 'ms':
94
- return n;
95
- default:
96
- return undefined;
97
- }
98
- }
99
-
100
- /**
101
- * Short format for `ms`.
102
- *
103
- * @param {Number} ms
104
- * @return {String}
105
- * @api private
106
- */
107
-
108
- function fmtShort(ms) {
109
- if (ms >= d) {
110
- return Math.round(ms / d) + 'd';
111
- }
112
- if (ms >= h) {
113
- return Math.round(ms / h) + 'h';
114
- }
115
- if (ms >= m) {
116
- return Math.round(ms / m) + 'm';
117
- }
118
- if (ms >= s) {
119
- return Math.round(ms / s) + 's';
120
- }
121
- return ms + 'ms';
122
- }
123
-
124
- /**
125
- * Long format for `ms`.
126
- *
127
- * @param {Number} ms
128
- * @return {String}
129
- * @api private
130
- */
131
-
132
- function fmtLong(ms) {
133
- return plural(ms, d, 'day') ||
134
- plural(ms, h, 'hour') ||
135
- plural(ms, m, 'minute') ||
136
- plural(ms, s, 'second') ||
137
- ms + ' ms';
138
- }
139
-
140
- /**
141
- * Pluralization helper.
142
- */
143
-
144
- function plural(ms, n, name) {
145
- if (ms < n) {
146
- return;
147
- }
148
- if (ms < n * 1.5) {
149
- return Math.floor(ms / n) + ' ' + name;
150
- }
151
- return Math.ceil(ms / n) + ' ' + name + 's';
152
- }
@@ -1,21 +0,0 @@
1
- The MIT License (MIT)
2
-
3
- Copyright (c) 2016 Zeit, Inc.
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the "Software"), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in all
13
- copies or substantial portions of the Software.
14
-
15
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
- SOFTWARE.
@@ -1,37 +0,0 @@
1
- {
2
- "name": "ms",
3
- "version": "2.0.0",
4
- "description": "Tiny milisecond conversion utility",
5
- "repository": "zeit/ms",
6
- "main": "./index",
7
- "files": [
8
- "index.js"
9
- ],
10
- "scripts": {
11
- "precommit": "lint-staged",
12
- "lint": "eslint lib/* bin/*",
13
- "test": "mocha tests.js"
14
- },
15
- "eslintConfig": {
16
- "extends": "eslint:recommended",
17
- "env": {
18
- "node": true,
19
- "es6": true
20
- }
21
- },
22
- "lint-staged": {
23
- "*.js": [
24
- "npm run lint",
25
- "prettier --single-quote --write",
26
- "git add"
27
- ]
28
- },
29
- "license": "MIT",
30
- "devDependencies": {
31
- "eslint": "3.19.0",
32
- "expect.js": "0.3.1",
33
- "husky": "0.13.3",
34
- "lint-staged": "3.4.1",
35
- "mocha": "3.4.1"
36
- }
37
- }
@@ -1,51 +0,0 @@
1
- # ms
2
-
3
- [![Build Status](https://travis-ci.org/zeit/ms.svg?branch=master)](https://travis-ci.org/zeit/ms)
4
- [![Slack Channel](http://zeit-slackin.now.sh/badge.svg)](https://zeit.chat/)
5
-
6
- Use this package to easily convert various time formats to milliseconds.
7
-
8
- ## Examples
9
-
10
- ```js
11
- ms('2 days') // 172800000
12
- ms('1d') // 86400000
13
- ms('10h') // 36000000
14
- ms('2.5 hrs') // 9000000
15
- ms('2h') // 7200000
16
- ms('1m') // 60000
17
- ms('5s') // 5000
18
- ms('1y') // 31557600000
19
- ms('100') // 100
20
- ```
21
-
22
- ### Convert from milliseconds
23
-
24
- ```js
25
- ms(60000) // "1m"
26
- ms(2 * 60000) // "2m"
27
- ms(ms('10 hours')) // "10h"
28
- ```
29
-
30
- ### Time format written-out
31
-
32
- ```js
33
- ms(60000, { long: true }) // "1 minute"
34
- ms(2 * 60000, { long: true }) // "2 minutes"
35
- ms(ms('10 hours'), { long: true }) // "10 hours"
36
- ```
37
-
38
- ## Features
39
-
40
- - Works both in [node](https://nodejs.org) and in the browser.
41
- - If a number is supplied to `ms`, a string with a unit is returned.
42
- - If a string that contains the number is supplied, it returns it as a number (e.g.: it returns `100` for `'100'`).
43
- - If you pass a string with a number and a valid unit, the number of equivalent ms is returned.
44
-
45
- ## Caught a bug?
46
-
47
- 1. [Fork](https://help.github.com/articles/fork-a-repo/) this repository to your own GitHub account and then [clone](https://help.github.com/articles/cloning-a-repository/) it to your local device
48
- 2. Link the package to the global module directory: `npm link`
49
- 3. Within the module you want to test your local development instance of ms, just link it to the dependencies: `npm link ms`. Instead of the default one from npm, node will now use your clone of ms!
50
-
51
- As always, you can run the tests using: `npm test`
@@ -1,103 +0,0 @@
1
- 0.6.2 / 2019-04-29
2
- ==================
3
-
4
- * Fix sorting charset, encoding, and language with extra parameters
5
-
6
- 0.6.1 / 2016-05-02
7
- ==================
8
-
9
- * perf: improve `Accept` parsing speed
10
- * perf: improve `Accept-Charset` parsing speed
11
- * perf: improve `Accept-Encoding` parsing speed
12
- * perf: improve `Accept-Language` parsing speed
13
-
14
- 0.6.0 / 2015-09-29
15
- ==================
16
-
17
- * Fix including type extensions in parameters in `Accept` parsing
18
- * Fix parsing `Accept` parameters with quoted equals
19
- * Fix parsing `Accept` parameters with quoted semicolons
20
- * Lazy-load modules from main entry point
21
- * perf: delay type concatenation until needed
22
- * perf: enable strict mode
23
- * perf: hoist regular expressions
24
- * perf: remove closures getting spec properties
25
- * perf: remove a closure from media type parsing
26
- * perf: remove property delete from media type parsing
27
-
28
- 0.5.3 / 2015-05-10
29
- ==================
30
-
31
- * Fix media type parameter matching to be case-insensitive
32
-
33
- 0.5.2 / 2015-05-06
34
- ==================
35
-
36
- * Fix comparing media types with quoted values
37
- * Fix splitting media types with quoted commas
38
-
39
- 0.5.1 / 2015-02-14
40
- ==================
41
-
42
- * Fix preference sorting to be stable for long acceptable lists
43
-
44
- 0.5.0 / 2014-12-18
45
- ==================
46
-
47
- * Fix list return order when large accepted list
48
- * Fix missing identity encoding when q=0 exists
49
- * Remove dynamic building of Negotiator class
50
-
51
- 0.4.9 / 2014-10-14
52
- ==================
53
-
54
- * Fix error when media type has invalid parameter
55
-
56
- 0.4.8 / 2014-09-28
57
- ==================
58
-
59
- * Fix all negotiations to be case-insensitive
60
- * Stable sort preferences of same quality according to client order
61
- * Support Node.js 0.6
62
-
63
- 0.4.7 / 2014-06-24
64
- ==================
65
-
66
- * Handle invalid provided languages
67
- * Handle invalid provided media types
68
-
69
- 0.4.6 / 2014-06-11
70
- ==================
71
-
72
- * Order by specificity when quality is the same
73
-
74
- 0.4.5 / 2014-05-29
75
- ==================
76
-
77
- * Fix regression in empty header handling
78
-
79
- 0.4.4 / 2014-05-29
80
- ==================
81
-
82
- * Fix behaviors when headers are not present
83
-
84
- 0.4.3 / 2014-04-16
85
- ==================
86
-
87
- * Handle slashes on media params correctly
88
-
89
- 0.4.2 / 2014-02-28
90
- ==================
91
-
92
- * Fix media type sorting
93
- * Handle media types params strictly
94
-
95
- 0.4.1 / 2014-01-16
96
- ==================
97
-
98
- * Use most specific matches
99
-
100
- 0.4.0 / 2014-01-09
101
- ==================
102
-
103
- * Remove preferred prefix from methods
@@ -1,24 +0,0 @@
1
- (The MIT License)
2
-
3
- Copyright (c) 2012-2014 Federico Romero
4
- Copyright (c) 2012-2014 Isaac Z. Schlueter
5
- Copyright (c) 2014-2015 Douglas Christopher Wilson
6
-
7
- Permission is hereby granted, free of charge, to any person obtaining
8
- a copy of this software and associated documentation files (the
9
- 'Software'), to deal in the Software without restriction, including
10
- without limitation the rights to use, copy, modify, merge, publish,
11
- distribute, sublicense, and/or sell copies of the Software, and to
12
- permit persons to whom the Software is furnished to do so, subject to
13
- the following conditions:
14
-
15
- The above copyright notice and this permission notice shall be
16
- included in all copies or substantial portions of the Software.
17
-
18
- THE SOFTWARE IS PROVIDED 'AS IS', WITHOUT WARRANTY OF ANY KIND,
19
- EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
20
- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
21
- IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
22
- CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
23
- TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
24
- SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.