webpack_rails 0.3.0 → 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (353) hide show
  1. checksums.yaml +4 -4
  2. data/lib/webpack_rails/ErrorMessagePlugin.js +37 -0
  3. data/lib/webpack_rails/engine.rb +6 -5
  4. data/lib/webpack_rails/node_modules/cors/CONTRIBUTING.md +35 -0
  5. data/lib/webpack_rails/node_modules/cors/LICENSE +9 -0
  6. data/lib/webpack_rails/node_modules/cors/README.md +192 -0
  7. data/lib/webpack_rails/node_modules/cors/lib/index.js +242 -0
  8. data/lib/webpack_rails/node_modules/cors/node_modules/vary/HISTORY.md +29 -0
  9. data/lib/webpack_rails/node_modules/cors/node_modules/vary/LICENSE +22 -0
  10. data/lib/webpack_rails/node_modules/cors/node_modules/vary/README.md +91 -0
  11. data/lib/webpack_rails/node_modules/cors/node_modules/vary/index.js +124 -0
  12. data/lib/webpack_rails/node_modules/cors/node_modules/vary/package.json +72 -0
  13. data/lib/webpack_rails/node_modules/cors/package.json +79 -0
  14. data/lib/webpack_rails/node_modules/cors/test/basic-auth.js +40 -0
  15. data/lib/webpack_rails/node_modules/cors/test/body-events.js +81 -0
  16. data/lib/webpack_rails/node_modules/cors/test/cors.js +652 -0
  17. data/lib/webpack_rails/node_modules/cors/test/error-response.js +77 -0
  18. data/lib/webpack_rails/node_modules/cors/test/example-app.js +98 -0
  19. data/lib/webpack_rails/node_modules/cors/test/issue-2.js +56 -0
  20. data/lib/webpack_rails/node_modules/cors/test/issue-31.js +58 -0
  21. data/lib/webpack_rails/node_modules/cors/test/mocha.opts +3 -0
  22. data/lib/webpack_rails/node_modules/express/History.md +3025 -0
  23. data/lib/webpack_rails/node_modules/express/LICENSE +24 -0
  24. data/lib/webpack_rails/node_modules/express/Readme.md +138 -0
  25. data/lib/webpack_rails/node_modules/express/index.js +11 -0
  26. data/lib/webpack_rails/node_modules/express/lib/application.js +643 -0
  27. data/lib/webpack_rails/node_modules/express/lib/express.js +103 -0
  28. data/lib/webpack_rails/node_modules/express/lib/middleware/init.js +36 -0
  29. data/lib/webpack_rails/node_modules/express/lib/middleware/query.js +51 -0
  30. data/lib/webpack_rails/node_modules/express/lib/request.js +489 -0
  31. data/lib/webpack_rails/node_modules/express/lib/response.js +1053 -0
  32. data/lib/webpack_rails/node_modules/express/lib/router/index.js +645 -0
  33. data/lib/webpack_rails/node_modules/express/lib/router/layer.js +176 -0
  34. data/lib/webpack_rails/node_modules/express/lib/router/route.js +210 -0
  35. data/lib/webpack_rails/node_modules/express/lib/utils.js +300 -0
  36. data/lib/webpack_rails/node_modules/express/lib/view.js +173 -0
  37. data/lib/webpack_rails/node_modules/express/node_modules/accepts/HISTORY.md +170 -0
  38. data/lib/webpack_rails/node_modules/express/node_modules/accepts/LICENSE +23 -0
  39. data/lib/webpack_rails/node_modules/express/node_modules/accepts/README.md +135 -0
  40. data/lib/webpack_rails/node_modules/express/node_modules/accepts/index.js +231 -0
  41. data/lib/webpack_rails/node_modules/express/node_modules/accepts/node_modules/mime-types/HISTORY.md +171 -0
  42. data/lib/webpack_rails/node_modules/express/node_modules/accepts/node_modules/mime-types/LICENSE +23 -0
  43. data/lib/webpack_rails/node_modules/express/node_modules/accepts/node_modules/mime-types/README.md +103 -0
  44. data/lib/webpack_rails/node_modules/express/node_modules/accepts/node_modules/mime-types/index.js +188 -0
  45. data/lib/webpack_rails/node_modules/express/node_modules/accepts/node_modules/mime-types/node_modules/mime-db/HISTORY.md +274 -0
  46. data/lib/webpack_rails/node_modules/express/node_modules/accepts/node_modules/mime-types/node_modules/mime-db/LICENSE +22 -0
  47. data/lib/webpack_rails/node_modules/express/node_modules/accepts/node_modules/mime-types/node_modules/mime-db/README.md +82 -0
  48. data/lib/webpack_rails/node_modules/express/node_modules/accepts/node_modules/mime-types/node_modules/mime-db/db.json +6474 -0
  49. data/lib/webpack_rails/node_modules/express/node_modules/accepts/node_modules/mime-types/node_modules/mime-db/index.js +11 -0
  50. data/lib/webpack_rails/node_modules/express/node_modules/accepts/node_modules/mime-types/node_modules/mime-db/package.json +94 -0
  51. data/lib/webpack_rails/node_modules/express/node_modules/accepts/node_modules/mime-types/package.json +84 -0
  52. data/lib/webpack_rails/node_modules/express/node_modules/accepts/node_modules/negotiator/HISTORY.md +76 -0
  53. data/lib/webpack_rails/node_modules/express/node_modules/accepts/node_modules/negotiator/LICENSE +24 -0
  54. data/lib/webpack_rails/node_modules/express/node_modules/accepts/node_modules/negotiator/README.md +203 -0
  55. data/lib/webpack_rails/node_modules/express/node_modules/accepts/node_modules/negotiator/index.js +62 -0
  56. data/lib/webpack_rails/node_modules/express/node_modules/accepts/node_modules/negotiator/lib/charset.js +102 -0
  57. data/lib/webpack_rails/node_modules/express/node_modules/accepts/node_modules/negotiator/lib/encoding.js +118 -0
  58. data/lib/webpack_rails/node_modules/express/node_modules/accepts/node_modules/negotiator/lib/language.js +112 -0
  59. data/lib/webpack_rails/node_modules/express/node_modules/accepts/node_modules/negotiator/lib/mediaType.js +179 -0
  60. data/lib/webpack_rails/node_modules/express/node_modules/accepts/node_modules/negotiator/package.json +86 -0
  61. data/lib/webpack_rails/node_modules/express/node_modules/accepts/package.json +98 -0
  62. data/lib/webpack_rails/node_modules/express/node_modules/array-flatten/LICENSE +21 -0
  63. data/lib/webpack_rails/node_modules/express/node_modules/array-flatten/README.md +43 -0
  64. data/lib/webpack_rails/node_modules/express/node_modules/array-flatten/array-flatten.js +64 -0
  65. data/lib/webpack_rails/node_modules/express/node_modules/array-flatten/package.json +62 -0
  66. data/lib/webpack_rails/node_modules/express/node_modules/content-disposition/HISTORY.md +40 -0
  67. data/lib/webpack_rails/node_modules/express/node_modules/content-disposition/LICENSE +22 -0
  68. data/lib/webpack_rails/node_modules/express/node_modules/content-disposition/README.md +141 -0
  69. data/lib/webpack_rails/node_modules/express/node_modules/content-disposition/index.js +443 -0
  70. data/lib/webpack_rails/node_modules/express/node_modules/content-disposition/package.json +66 -0
  71. data/lib/webpack_rails/node_modules/express/node_modules/content-type/HISTORY.md +9 -0
  72. data/lib/webpack_rails/node_modules/express/node_modules/content-type/LICENSE +22 -0
  73. data/lib/webpack_rails/node_modules/express/node_modules/content-type/README.md +92 -0
  74. data/lib/webpack_rails/node_modules/express/node_modules/content-type/index.js +214 -0
  75. data/lib/webpack_rails/node_modules/express/node_modules/content-type/package.json +65 -0
  76. data/lib/webpack_rails/node_modules/express/node_modules/cookie/LICENSE +23 -0
  77. data/lib/webpack_rails/node_modules/express/node_modules/cookie/README.md +64 -0
  78. data/lib/webpack_rails/node_modules/express/node_modules/cookie/index.js +116 -0
  79. data/lib/webpack_rails/node_modules/express/node_modules/cookie/package.json +68 -0
  80. data/lib/webpack_rails/node_modules/express/node_modules/cookie-signature/History.md +38 -0
  81. data/lib/webpack_rails/node_modules/express/node_modules/cookie-signature/Readme.md +42 -0
  82. data/lib/webpack_rails/node_modules/express/node_modules/cookie-signature/index.js +51 -0
  83. data/lib/webpack_rails/node_modules/express/node_modules/cookie-signature/package.json +59 -0
  84. data/lib/webpack_rails/node_modules/express/node_modules/debug/History.md +195 -0
  85. data/lib/webpack_rails/node_modules/express/node_modules/debug/Makefile +36 -0
  86. data/lib/webpack_rails/node_modules/express/node_modules/debug/Readme.md +188 -0
  87. data/lib/webpack_rails/node_modules/express/node_modules/debug/bower.json +28 -0
  88. data/lib/webpack_rails/node_modules/express/node_modules/debug/browser.js +168 -0
  89. data/lib/webpack_rails/node_modules/express/node_modules/debug/component.json +19 -0
  90. data/lib/webpack_rails/node_modules/express/node_modules/debug/debug.js +197 -0
  91. data/lib/webpack_rails/node_modules/express/node_modules/debug/node.js +209 -0
  92. data/lib/webpack_rails/node_modules/express/node_modules/debug/node_modules/ms/History.md +66 -0
  93. data/lib/webpack_rails/node_modules/express/node_modules/debug/node_modules/ms/LICENSE +20 -0
  94. data/lib/webpack_rails/node_modules/express/node_modules/debug/node_modules/ms/README.md +35 -0
  95. data/lib/webpack_rails/node_modules/express/node_modules/debug/node_modules/ms/index.js +125 -0
  96. data/lib/webpack_rails/node_modules/express/node_modules/debug/node_modules/ms/package.json +47 -0
  97. data/lib/webpack_rails/node_modules/express/node_modules/debug/package.json +73 -0
  98. data/lib/webpack_rails/node_modules/express/node_modules/depd/History.md +75 -0
  99. data/lib/webpack_rails/node_modules/express/node_modules/depd/LICENSE +22 -0
  100. data/lib/webpack_rails/node_modules/express/node_modules/depd/Readme.md +274 -0
  101. data/lib/webpack_rails/node_modules/express/node_modules/depd/index.js +529 -0
  102. data/lib/webpack_rails/node_modules/express/node_modules/depd/lib/compat/buffer-concat.js +33 -0
  103. data/lib/webpack_rails/node_modules/express/node_modules/depd/lib/compat/callsite-tostring.js +101 -0
  104. data/lib/webpack_rails/node_modules/express/node_modules/depd/lib/compat/index.js +69 -0
  105. data/lib/webpack_rails/node_modules/express/node_modules/depd/package.json +66 -0
  106. data/lib/webpack_rails/node_modules/express/node_modules/escape-html/LICENSE +22 -0
  107. data/lib/webpack_rails/node_modules/express/node_modules/escape-html/Readme.md +15 -0
  108. data/lib/webpack_rails/node_modules/express/node_modules/escape-html/index.js +29 -0
  109. data/lib/webpack_rails/node_modules/express/node_modules/escape-html/package.json +51 -0
  110. data/lib/webpack_rails/node_modules/express/node_modules/etag/HISTORY.md +71 -0
  111. data/lib/webpack_rails/node_modules/express/node_modules/etag/LICENSE +22 -0
  112. data/lib/webpack_rails/node_modules/express/node_modules/etag/README.md +165 -0
  113. data/lib/webpack_rails/node_modules/express/node_modules/etag/index.js +132 -0
  114. data/lib/webpack_rails/node_modules/express/node_modules/etag/package.json +73 -0
  115. data/lib/webpack_rails/node_modules/express/node_modules/finalhandler/HISTORY.md +90 -0
  116. data/lib/webpack_rails/node_modules/express/node_modules/finalhandler/LICENSE +22 -0
  117. data/lib/webpack_rails/node_modules/express/node_modules/finalhandler/README.md +133 -0
  118. data/lib/webpack_rails/node_modules/express/node_modules/finalhandler/index.js +151 -0
  119. data/lib/webpack_rails/node_modules/express/node_modules/finalhandler/node_modules/unpipe/HISTORY.md +4 -0
  120. data/lib/webpack_rails/node_modules/express/node_modules/finalhandler/node_modules/unpipe/LICENSE +22 -0
  121. data/lib/webpack_rails/node_modules/express/node_modules/finalhandler/node_modules/unpipe/README.md +43 -0
  122. data/lib/webpack_rails/node_modules/express/node_modules/finalhandler/node_modules/unpipe/index.js +69 -0
  123. data/lib/webpack_rails/node_modules/express/node_modules/finalhandler/node_modules/unpipe/package.json +59 -0
  124. data/lib/webpack_rails/node_modules/express/node_modules/finalhandler/package.json +81 -0
  125. data/lib/webpack_rails/node_modules/express/node_modules/fresh/HISTORY.md +38 -0
  126. data/lib/webpack_rails/node_modules/express/node_modules/fresh/LICENSE +22 -0
  127. data/lib/webpack_rails/node_modules/express/node_modules/fresh/README.md +58 -0
  128. data/lib/webpack_rails/node_modules/express/node_modules/fresh/index.js +57 -0
  129. data/lib/webpack_rails/node_modules/express/node_modules/fresh/package.json +87 -0
  130. data/lib/webpack_rails/node_modules/express/node_modules/merge-descriptors/LICENSE +22 -0
  131. data/lib/webpack_rails/node_modules/express/node_modules/merge-descriptors/README.md +34 -0
  132. data/lib/webpack_rails/node_modules/express/node_modules/merge-descriptors/index.js +57 -0
  133. data/lib/webpack_rails/node_modules/express/node_modules/merge-descriptors/package.json +125 -0
  134. data/lib/webpack_rails/node_modules/express/node_modules/methods/HISTORY.md +24 -0
  135. data/lib/webpack_rails/node_modules/express/node_modules/methods/LICENSE +23 -0
  136. data/lib/webpack_rails/node_modules/express/node_modules/methods/README.md +41 -0
  137. data/lib/webpack_rails/node_modules/express/node_modules/methods/index.js +42 -0
  138. data/lib/webpack_rails/node_modules/express/node_modules/methods/package.json +88 -0
  139. data/lib/webpack_rails/node_modules/express/node_modules/on-finished/HISTORY.md +88 -0
  140. data/lib/webpack_rails/node_modules/express/node_modules/on-finished/LICENSE +23 -0
  141. data/lib/webpack_rails/node_modules/express/node_modules/on-finished/README.md +154 -0
  142. data/lib/webpack_rails/node_modules/express/node_modules/on-finished/index.js +196 -0
  143. data/lib/webpack_rails/node_modules/express/node_modules/on-finished/node_modules/ee-first/LICENSE +22 -0
  144. data/lib/webpack_rails/node_modules/express/node_modules/on-finished/node_modules/ee-first/README.md +80 -0
  145. data/lib/webpack_rails/node_modules/express/node_modules/on-finished/node_modules/ee-first/index.js +95 -0
  146. data/lib/webpack_rails/node_modules/express/node_modules/on-finished/node_modules/ee-first/package.json +64 -0
  147. data/lib/webpack_rails/node_modules/express/node_modules/on-finished/package.json +71 -0
  148. data/lib/webpack_rails/node_modules/express/node_modules/parseurl/HISTORY.md +42 -0
  149. data/lib/webpack_rails/node_modules/express/node_modules/parseurl/LICENSE +24 -0
  150. data/lib/webpack_rails/node_modules/express/node_modules/parseurl/README.md +107 -0
  151. data/lib/webpack_rails/node_modules/express/node_modules/parseurl/index.js +136 -0
  152. data/lib/webpack_rails/node_modules/express/node_modules/parseurl/package.json +80 -0
  153. data/lib/webpack_rails/node_modules/express/node_modules/path-to-regexp/History.md +36 -0
  154. data/lib/webpack_rails/node_modules/express/node_modules/path-to-regexp/LICENSE +21 -0
  155. data/lib/webpack_rails/node_modules/express/node_modules/path-to-regexp/Readme.md +35 -0
  156. data/lib/webpack_rails/node_modules/express/node_modules/path-to-regexp/index.js +129 -0
  157. data/lib/webpack_rails/node_modules/express/node_modules/path-to-regexp/package.json +184 -0
  158. data/lib/webpack_rails/node_modules/express/node_modules/proxy-addr/HISTORY.md +66 -0
  159. data/lib/webpack_rails/node_modules/express/node_modules/proxy-addr/LICENSE +22 -0
  160. data/lib/webpack_rails/node_modules/express/node_modules/proxy-addr/README.md +137 -0
  161. data/lib/webpack_rails/node_modules/express/node_modules/proxy-addr/index.js +345 -0
  162. data/lib/webpack_rails/node_modules/express/node_modules/proxy-addr/node_modules/forwarded/HISTORY.md +4 -0
  163. data/lib/webpack_rails/node_modules/express/node_modules/proxy-addr/node_modules/forwarded/LICENSE +22 -0
  164. data/lib/webpack_rails/node_modules/express/node_modules/proxy-addr/node_modules/forwarded/README.md +53 -0
  165. data/lib/webpack_rails/node_modules/express/node_modules/proxy-addr/node_modules/forwarded/index.js +35 -0
  166. data/lib/webpack_rails/node_modules/express/node_modules/proxy-addr/node_modules/forwarded/package.json +65 -0
  167. data/lib/webpack_rails/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/Cakefile +18 -0
  168. data/lib/webpack_rails/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/LICENSE +19 -0
  169. data/lib/webpack_rails/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/README.md +161 -0
  170. data/lib/webpack_rails/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/ipaddr.min.js +1 -0
  171. data/lib/webpack_rails/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/lib/ipaddr.js +439 -0
  172. data/lib/webpack_rails/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/package.json +60 -0
  173. data/lib/webpack_rails/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/src/ipaddr.coffee +374 -0
  174. data/lib/webpack_rails/node_modules/express/node_modules/proxy-addr/node_modules/ipaddr.js/test/ipaddr.test.coffee +262 -0
  175. data/lib/webpack_rails/node_modules/express/node_modules/proxy-addr/package.json +90 -0
  176. data/lib/webpack_rails/node_modules/express/node_modules/qs/CHANGELOG.md +88 -0
  177. data/lib/webpack_rails/node_modules/express/node_modules/qs/CONTRIBUTING.md +1 -0
  178. data/lib/webpack_rails/node_modules/express/node_modules/qs/LICENSE +28 -0
  179. data/lib/webpack_rails/node_modules/express/node_modules/qs/README.md +317 -0
  180. data/lib/webpack_rails/node_modules/express/node_modules/qs/bower.json +22 -0
  181. data/lib/webpack_rails/node_modules/express/node_modules/qs/lib/index.js +15 -0
  182. data/lib/webpack_rails/node_modules/express/node_modules/qs/lib/parse.js +186 -0
  183. data/lib/webpack_rails/node_modules/express/node_modules/qs/lib/stringify.js +121 -0
  184. data/lib/webpack_rails/node_modules/express/node_modules/qs/lib/utils.js +190 -0
  185. data/lib/webpack_rails/node_modules/express/node_modules/qs/package.json +56 -0
  186. data/lib/webpack_rails/node_modules/express/node_modules/qs/test/parse.js +478 -0
  187. data/lib/webpack_rails/node_modules/express/node_modules/qs/test/stringify.js +259 -0
  188. data/lib/webpack_rails/node_modules/express/node_modules/qs/test/utils.js +28 -0
  189. data/lib/webpack_rails/node_modules/express/node_modules/range-parser/HISTORY.md +35 -0
  190. data/lib/webpack_rails/node_modules/express/node_modules/range-parser/LICENSE +22 -0
  191. data/lib/webpack_rails/node_modules/express/node_modules/range-parser/README.md +48 -0
  192. data/lib/webpack_rails/node_modules/express/node_modules/range-parser/index.js +49 -0
  193. data/lib/webpack_rails/node_modules/express/node_modules/range-parser/package.json +76 -0
  194. data/lib/webpack_rails/node_modules/express/node_modules/send/HISTORY.md +295 -0
  195. data/lib/webpack_rails/node_modules/express/node_modules/send/LICENSE +23 -0
  196. data/lib/webpack_rails/node_modules/express/node_modules/send/README.md +195 -0
  197. data/lib/webpack_rails/node_modules/express/node_modules/send/index.js +820 -0
  198. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/destroy/README.md +38 -0
  199. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/destroy/index.js +36 -0
  200. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/destroy/package.json +67 -0
  201. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/http-errors/HISTORY.md +76 -0
  202. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/http-errors/LICENSE +22 -0
  203. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/http-errors/README.md +63 -0
  204. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/http-errors/index.js +120 -0
  205. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/http-errors/node_modules/inherits/LICENSE +16 -0
  206. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/http-errors/node_modules/inherits/README.md +42 -0
  207. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/http-errors/node_modules/inherits/inherits.js +1 -0
  208. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/http-errors/node_modules/inherits/inherits_browser.js +23 -0
  209. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/http-errors/node_modules/inherits/package.json +50 -0
  210. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/http-errors/node_modules/inherits/test.js +25 -0
  211. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/http-errors/package.json +85 -0
  212. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/mime/LICENSE +19 -0
  213. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/mime/README.md +90 -0
  214. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/mime/build/build.js +11 -0
  215. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/mime/build/test.js +57 -0
  216. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/mime/cli.js +8 -0
  217. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/mime/mime.js +108 -0
  218. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/mime/package.json +73 -0
  219. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/mime/types.json +1 -0
  220. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/ms/History.md +66 -0
  221. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/ms/LICENSE +20 -0
  222. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/ms/README.md +35 -0
  223. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/ms/index.js +125 -0
  224. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/ms/package.json +47 -0
  225. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/statuses/LICENSE +22 -0
  226. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/statuses/README.md +114 -0
  227. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/statuses/codes.json +64 -0
  228. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/statuses/index.js +60 -0
  229. data/lib/webpack_rails/node_modules/express/node_modules/send/node_modules/statuses/package.json +84 -0
  230. data/lib/webpack_rails/node_modules/express/node_modules/send/package.json +89 -0
  231. data/lib/webpack_rails/node_modules/express/node_modules/serve-static/HISTORY.md +284 -0
  232. data/lib/webpack_rails/node_modules/express/node_modules/serve-static/LICENSE +25 -0
  233. data/lib/webpack_rails/node_modules/express/node_modules/serve-static/README.md +235 -0
  234. data/lib/webpack_rails/node_modules/express/node_modules/serve-static/index.js +187 -0
  235. data/lib/webpack_rails/node_modules/express/node_modules/serve-static/package.json +83 -0
  236. data/lib/webpack_rails/node_modules/express/node_modules/type-is/HISTORY.md +180 -0
  237. data/lib/webpack_rails/node_modules/express/node_modules/type-is/LICENSE +23 -0
  238. data/lib/webpack_rails/node_modules/express/node_modules/type-is/README.md +132 -0
  239. data/lib/webpack_rails/node_modules/express/node_modules/type-is/index.js +262 -0
  240. data/lib/webpack_rails/node_modules/express/node_modules/type-is/node_modules/media-typer/HISTORY.md +22 -0
  241. data/lib/webpack_rails/node_modules/express/node_modules/type-is/node_modules/media-typer/LICENSE +22 -0
  242. data/lib/webpack_rails/node_modules/express/node_modules/type-is/node_modules/media-typer/README.md +81 -0
  243. data/lib/webpack_rails/node_modules/express/node_modules/type-is/node_modules/media-typer/index.js +270 -0
  244. data/lib/webpack_rails/node_modules/express/node_modules/type-is/node_modules/media-typer/package.json +58 -0
  245. data/lib/webpack_rails/node_modules/express/node_modules/type-is/node_modules/mime-types/HISTORY.md +171 -0
  246. data/lib/webpack_rails/node_modules/express/node_modules/type-is/node_modules/mime-types/LICENSE +23 -0
  247. data/lib/webpack_rails/node_modules/express/node_modules/type-is/node_modules/mime-types/README.md +103 -0
  248. data/lib/webpack_rails/node_modules/express/node_modules/type-is/node_modules/mime-types/index.js +188 -0
  249. data/lib/webpack_rails/node_modules/express/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/HISTORY.md +274 -0
  250. data/lib/webpack_rails/node_modules/express/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/LICENSE +22 -0
  251. data/lib/webpack_rails/node_modules/express/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/README.md +82 -0
  252. data/lib/webpack_rails/node_modules/express/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/db.json +6474 -0
  253. data/lib/webpack_rails/node_modules/express/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/index.js +11 -0
  254. data/lib/webpack_rails/node_modules/express/node_modules/type-is/node_modules/mime-types/node_modules/mime-db/package.json +94 -0
  255. data/lib/webpack_rails/node_modules/express/node_modules/type-is/node_modules/mime-types/package.json +84 -0
  256. data/lib/webpack_rails/node_modules/express/node_modules/type-is/package.json +93 -0
  257. data/lib/webpack_rails/node_modules/express/node_modules/utils-merge/LICENSE +20 -0
  258. data/lib/webpack_rails/node_modules/express/node_modules/utils-merge/README.md +34 -0
  259. data/lib/webpack_rails/node_modules/express/node_modules/utils-merge/index.js +23 -0
  260. data/lib/webpack_rails/node_modules/express/node_modules/utils-merge/package.json +58 -0
  261. data/lib/webpack_rails/node_modules/express/node_modules/vary/HISTORY.md +23 -0
  262. data/lib/webpack_rails/node_modules/express/node_modules/vary/LICENSE +22 -0
  263. data/lib/webpack_rails/node_modules/express/node_modules/vary/README.md +91 -0
  264. data/lib/webpack_rails/node_modules/express/node_modules/vary/index.js +117 -0
  265. data/lib/webpack_rails/node_modules/express/node_modules/vary/package.json +72 -0
  266. data/lib/webpack_rails/node_modules/express/package.json +167 -0
  267. data/lib/webpack_rails/node_modules/is-array/History.md +11 -0
  268. data/lib/webpack_rails/node_modules/is-array/Makefile +11 -0
  269. data/lib/webpack_rails/node_modules/is-array/Readme.md +27 -0
  270. data/lib/webpack_rails/node_modules/is-array/component.json +13 -0
  271. data/lib/webpack_rails/node_modules/is-array/index.js +33 -0
  272. data/lib/webpack_rails/node_modules/is-array/package.json +41 -0
  273. data/lib/webpack_rails/node_modules/is-array/test/test.html +46 -0
  274. data/lib/webpack_rails/node_modules/is-object/LICENSE +19 -0
  275. data/lib/webpack_rails/node_modules/is-object/README.md +55 -0
  276. data/lib/webpack_rails/node_modules/is-object/index.js +5 -0
  277. data/lib/webpack_rails/node_modules/is-object/package.json +91 -0
  278. data/lib/webpack_rails/node_modules/is-object/test/index.js +23 -0
  279. data/lib/webpack_rails/node_modules/is-string/CHANGELOG.md +19 -0
  280. data/lib/webpack_rails/node_modules/is-string/LICENSE +22 -0
  281. data/lib/webpack_rails/node_modules/is-string/Makefile +61 -0
  282. data/lib/webpack_rails/node_modules/is-string/README.md +57 -0
  283. data/lib/webpack_rails/node_modules/is-string/index.js +20 -0
  284. data/lib/webpack_rails/node_modules/is-string/package.json +93 -0
  285. data/lib/webpack_rails/node_modules/is-string/test.js +36 -0
  286. data/lib/webpack_rails/node_modules/js-string-escape/CHANGELOG.md +9 -0
  287. data/lib/webpack_rails/node_modules/js-string-escape/LICENSE +21 -0
  288. data/lib/webpack_rails/node_modules/js-string-escape/README.md +44 -0
  289. data/lib/webpack_rails/node_modules/js-string-escape/index.js +22 -0
  290. data/lib/webpack_rails/node_modules/js-string-escape/package.json +63 -0
  291. data/lib/webpack_rails/node_modules/js-string-escape/test/test.js +43 -0
  292. data/lib/webpack_rails/node_modules/strip-ansi/index.js +6 -0
  293. data/lib/webpack_rails/node_modules/strip-ansi/license +21 -0
  294. data/lib/webpack_rails/node_modules/strip-ansi/node_modules/ansi-regex/index.js +4 -0
  295. data/lib/webpack_rails/node_modules/strip-ansi/node_modules/ansi-regex/license +21 -0
  296. data/lib/webpack_rails/node_modules/strip-ansi/node_modules/ansi-regex/package.json +86 -0
  297. data/lib/webpack_rails/node_modules/strip-ansi/node_modules/ansi-regex/readme.md +31 -0
  298. data/lib/webpack_rails/node_modules/strip-ansi/package.json +85 -0
  299. data/lib/webpack_rails/node_modules/strip-ansi/readme.md +33 -0
  300. data/lib/webpack_rails/node_modules/webpack-hot-middleware/README.md +109 -0
  301. data/lib/webpack_rails/node_modules/webpack-hot-middleware/client-overlay.js +35 -0
  302. data/lib/webpack_rails/node_modules/webpack-hot-middleware/client.js +131 -0
  303. data/lib/webpack_rails/node_modules/webpack-hot-middleware/example/README.md +15 -0
  304. data/lib/webpack_rails/node_modules/webpack-hot-middleware/example/client.js +30 -0
  305. data/lib/webpack_rails/node_modules/webpack-hot-middleware/example/index.html +18 -0
  306. data/lib/webpack_rails/node_modules/webpack-hot-middleware/example/package.json +14 -0
  307. data/lib/webpack_rails/node_modules/webpack-hot-middleware/example/server.js +41 -0
  308. data/lib/webpack_rails/node_modules/webpack-hot-middleware/example/webpack.config.js +22 -0
  309. data/lib/webpack_rails/node_modules/webpack-hot-middleware/helpers.js +8 -0
  310. data/lib/webpack_rails/node_modules/webpack-hot-middleware/middleware.js +83 -0
  311. data/lib/webpack_rails/node_modules/webpack-hot-middleware/node_modules/querystring/History.md +20 -0
  312. data/lib/webpack_rails/node_modules/webpack-hot-middleware/node_modules/querystring/License.md +19 -0
  313. data/lib/webpack_rails/node_modules/webpack-hot-middleware/node_modules/querystring/Readme.md +15 -0
  314. data/lib/webpack_rails/node_modules/webpack-hot-middleware/node_modules/querystring/decode.js +80 -0
  315. data/lib/webpack_rails/node_modules/webpack-hot-middleware/node_modules/querystring/encode.js +64 -0
  316. data/lib/webpack_rails/node_modules/webpack-hot-middleware/node_modules/querystring/index.js +4 -0
  317. data/lib/webpack_rails/node_modules/webpack-hot-middleware/node_modules/querystring/package.json +96 -0
  318. data/lib/webpack_rails/node_modules/webpack-hot-middleware/node_modules/querystring/test/common-index.js +3 -0
  319. data/lib/webpack_rails/node_modules/webpack-hot-middleware/node_modules/querystring/test/index.js +210 -0
  320. data/lib/webpack_rails/node_modules/webpack-hot-middleware/node_modules/querystring/test/tap-index.js +3 -0
  321. data/lib/webpack_rails/node_modules/webpack-hot-middleware/node_modules/strip-ansi/cli.js +47 -0
  322. data/lib/webpack_rails/node_modules/webpack-hot-middleware/node_modules/strip-ansi/index.js +6 -0
  323. data/lib/webpack_rails/node_modules/webpack-hot-middleware/node_modules/strip-ansi/node_modules/ansi-regex/index.js +4 -0
  324. data/lib/webpack_rails/node_modules/webpack-hot-middleware/node_modules/strip-ansi/node_modules/ansi-regex/license +21 -0
  325. data/lib/webpack_rails/node_modules/webpack-hot-middleware/node_modules/strip-ansi/node_modules/ansi-regex/package.json +86 -0
  326. data/lib/webpack_rails/node_modules/webpack-hot-middleware/node_modules/strip-ansi/node_modules/ansi-regex/readme.md +33 -0
  327. data/lib/webpack_rails/node_modules/webpack-hot-middleware/node_modules/strip-ansi/package.json +89 -0
  328. data/lib/webpack_rails/node_modules/webpack-hot-middleware/node_modules/strip-ansi/readme.md +43 -0
  329. data/lib/webpack_rails/node_modules/webpack-hot-middleware/package.json +58 -0
  330. data/lib/webpack_rails/node_modules/webpack-hot-middleware/process-update.js +105 -0
  331. data/lib/webpack_rails/node_modules/webpack-hot-middleware/test/client-test.js +81 -0
  332. data/lib/webpack_rails/node_modules/webpack-hot-middleware/test/helpers-test.js +22 -0
  333. data/lib/webpack_rails/node_modules/webpack-hot-middleware/test/middleware-test.js +188 -0
  334. data/lib/webpack_rails/node_modules/webpack-hot-middleware/test/mocha.opts +1 -0
  335. data/lib/webpack_rails/node_modules/xtend/LICENCE +19 -0
  336. data/lib/webpack_rails/node_modules/xtend/Makefile +4 -0
  337. data/lib/webpack_rails/node_modules/xtend/README.md +32 -0
  338. data/lib/webpack_rails/node_modules/xtend/immutable.js +17 -0
  339. data/lib/webpack_rails/node_modules/xtend/mutable.js +15 -0
  340. data/lib/webpack_rails/node_modules/xtend/package.json +88 -0
  341. data/lib/webpack_rails/node_modules/xtend/test.js +63 -0
  342. data/lib/webpack_rails/package.json +22 -0
  343. data/lib/webpack_rails/processor.rb +28 -9
  344. data/lib/webpack_rails/require_directive_processor.rb +51 -0
  345. data/lib/webpack_rails/sprockets_environment.rb +45 -0
  346. data/lib/webpack_rails/task.rb +51 -22
  347. data/lib/webpack_rails/webpack-task-dev-server.js +122 -0
  348. data/lib/webpack_rails/{webpack-task.js → webpack-task-watch.js} +0 -0
  349. data/lib/webpack_rails/webpack.rake +5 -5
  350. data/lib/webpack_rails.rb +1 -3
  351. metadata +346 -5
  352. data/lib/webpack_rails/sprockets_base_webpack.rb +0 -14
  353. data/lib/webpack_rails/sprockets_index_webpack.rb +0 -15
@@ -0,0 +1,95 @@
1
+ /*!
2
+ * ee-first
3
+ * Copyright(c) 2014 Jonathan Ong
4
+ * MIT Licensed
5
+ */
6
+
7
+ 'use strict'
8
+
9
+ /**
10
+ * Module exports.
11
+ * @public
12
+ */
13
+
14
+ module.exports = first
15
+
16
+ /**
17
+ * Get the first event in a set of event emitters and event pairs.
18
+ *
19
+ * @param {array} stuff
20
+ * @param {function} done
21
+ * @public
22
+ */
23
+
24
+ function first(stuff, done) {
25
+ if (!Array.isArray(stuff))
26
+ throw new TypeError('arg must be an array of [ee, events...] arrays')
27
+
28
+ var cleanups = []
29
+
30
+ for (var i = 0; i < stuff.length; i++) {
31
+ var arr = stuff[i]
32
+
33
+ if (!Array.isArray(arr) || arr.length < 2)
34
+ throw new TypeError('each array member must be [ee, events...]')
35
+
36
+ var ee = arr[0]
37
+
38
+ for (var j = 1; j < arr.length; j++) {
39
+ var event = arr[j]
40
+ var fn = listener(event, callback)
41
+
42
+ // listen to the event
43
+ ee.on(event, fn)
44
+ // push this listener to the list of cleanups
45
+ cleanups.push({
46
+ ee: ee,
47
+ event: event,
48
+ fn: fn,
49
+ })
50
+ }
51
+ }
52
+
53
+ function callback() {
54
+ cleanup()
55
+ done.apply(null, arguments)
56
+ }
57
+
58
+ function cleanup() {
59
+ var x
60
+ for (var i = 0; i < cleanups.length; i++) {
61
+ x = cleanups[i]
62
+ x.ee.removeListener(x.event, x.fn)
63
+ }
64
+ }
65
+
66
+ function thunk(fn) {
67
+ done = fn
68
+ }
69
+
70
+ thunk.cancel = cleanup
71
+
72
+ return thunk
73
+ }
74
+
75
+ /**
76
+ * Create the event listener.
77
+ * @private
78
+ */
79
+
80
+ function listener(event, done) {
81
+ return function onevent(arg1) {
82
+ var args = new Array(arguments.length)
83
+ var ee = this
84
+ var err = event === 'error'
85
+ ? arg1
86
+ : null
87
+
88
+ // copy args to prevent arguments escaping scope
89
+ for (var i = 0; i < args.length; i++) {
90
+ args[i] = arguments[i]
91
+ }
92
+
93
+ done(err, ee, event, args)
94
+ }
95
+ }
@@ -0,0 +1,64 @@
1
+ {
2
+ "name": "ee-first",
3
+ "description": "return the first event in a set of ee/event pairs",
4
+ "version": "1.1.1",
5
+ "author": {
6
+ "name": "Jonathan Ong",
7
+ "email": "me@jongleberry.com",
8
+ "url": "http://jongleberry.com"
9
+ },
10
+ "contributors": [
11
+ {
12
+ "name": "Douglas Christopher Wilson",
13
+ "email": "doug@somethingdoug.com"
14
+ }
15
+ ],
16
+ "license": "MIT",
17
+ "repository": {
18
+ "type": "git",
19
+ "url": "git+https://github.com/jonathanong/ee-first.git"
20
+ },
21
+ "devDependencies": {
22
+ "istanbul": "0.3.9",
23
+ "mocha": "2.2.5"
24
+ },
25
+ "files": [
26
+ "index.js",
27
+ "LICENSE"
28
+ ],
29
+ "scripts": {
30
+ "test": "mocha --reporter spec --bail --check-leaks test/",
31
+ "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks test/",
32
+ "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks test/"
33
+ },
34
+ "gitHead": "512e0ce4cc3643f603708f965a97b61b1a9c0441",
35
+ "bugs": {
36
+ "url": "https://github.com/jonathanong/ee-first/issues"
37
+ },
38
+ "homepage": "https://github.com/jonathanong/ee-first",
39
+ "_id": "ee-first@1.1.1",
40
+ "_shasum": "590c61156b0ae2f4f0255732a158b266bc56b21d",
41
+ "_from": "ee-first@1.1.1",
42
+ "_npmVersion": "1.4.28",
43
+ "_npmUser": {
44
+ "name": "dougwilson",
45
+ "email": "doug@somethingdoug.com"
46
+ },
47
+ "maintainers": [
48
+ {
49
+ "name": "jongleberry",
50
+ "email": "jonathanrichardong@gmail.com"
51
+ },
52
+ {
53
+ "name": "dougwilson",
54
+ "email": "doug@somethingdoug.com"
55
+ }
56
+ ],
57
+ "dist": {
58
+ "shasum": "590c61156b0ae2f4f0255732a158b266bc56b21d",
59
+ "tarball": "http://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz"
60
+ },
61
+ "directories": {},
62
+ "_resolved": "http://registry.npmjs.org/ee-first/-/ee-first-1.1.1.tgz",
63
+ "readme": "ERROR: No README data found!"
64
+ }
@@ -0,0 +1,71 @@
1
+ {
2
+ "name": "on-finished",
3
+ "description": "Execute a callback when a request closes, finishes, or errors",
4
+ "version": "2.3.0",
5
+ "contributors": [
6
+ {
7
+ "name": "Douglas Christopher Wilson",
8
+ "email": "doug@somethingdoug.com"
9
+ },
10
+ {
11
+ "name": "Jonathan Ong",
12
+ "email": "me@jongleberry.com",
13
+ "url": "http://jongleberry.com"
14
+ }
15
+ ],
16
+ "license": "MIT",
17
+ "repository": {
18
+ "type": "git",
19
+ "url": "git+https://github.com/jshttp/on-finished.git"
20
+ },
21
+ "dependencies": {
22
+ "ee-first": "1.1.1"
23
+ },
24
+ "devDependencies": {
25
+ "istanbul": "0.3.9",
26
+ "mocha": "2.2.5"
27
+ },
28
+ "engines": {
29
+ "node": ">= 0.8"
30
+ },
31
+ "files": [
32
+ "HISTORY.md",
33
+ "LICENSE",
34
+ "index.js"
35
+ ],
36
+ "scripts": {
37
+ "test": "mocha --reporter spec --bail --check-leaks test/",
38
+ "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks test/",
39
+ "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks test/"
40
+ },
41
+ "gitHead": "34babcb58126a416fcf5205768204f2e12699dda",
42
+ "bugs": {
43
+ "url": "https://github.com/jshttp/on-finished/issues"
44
+ },
45
+ "homepage": "https://github.com/jshttp/on-finished",
46
+ "_id": "on-finished@2.3.0",
47
+ "_shasum": "20f1336481b083cd75337992a16971aa2d906947",
48
+ "_from": "on-finished@>=2.3.0 <2.4.0",
49
+ "_npmVersion": "1.4.28",
50
+ "_npmUser": {
51
+ "name": "dougwilson",
52
+ "email": "doug@somethingdoug.com"
53
+ },
54
+ "maintainers": [
55
+ {
56
+ "name": "dougwilson",
57
+ "email": "doug@somethingdoug.com"
58
+ },
59
+ {
60
+ "name": "jongleberry",
61
+ "email": "jonathanrichardong@gmail.com"
62
+ }
63
+ ],
64
+ "dist": {
65
+ "shasum": "20f1336481b083cd75337992a16971aa2d906947",
66
+ "tarball": "http://registry.npmjs.org/on-finished/-/on-finished-2.3.0.tgz"
67
+ },
68
+ "directories": {},
69
+ "_resolved": "http://registry.npmjs.org/on-finished/-/on-finished-2.3.0.tgz",
70
+ "readme": "ERROR: No README data found!"
71
+ }
@@ -0,0 +1,42 @@
1
+ 1.3.0 / 2014-08-09
2
+ ==================
3
+
4
+ * Add `parseurl.original` for parsing `req.originalUrl` with fallback
5
+ * Return `undefined` if `req.url` is `undefined`
6
+
7
+ 1.2.0 / 2014-07-21
8
+ ==================
9
+
10
+ * Cache URLs based on original value
11
+ * Remove no-longer-needed URL mis-parse work-around
12
+ * Simplify the "fast-path" `RegExp`
13
+
14
+ 1.1.3 / 2014-07-08
15
+ ==================
16
+
17
+ * Fix typo
18
+
19
+ 1.1.2 / 2014-07-08
20
+ ==================
21
+
22
+ * Seriously fix Node.js 0.8 compatibility
23
+
24
+ 1.1.1 / 2014-07-08
25
+ ==================
26
+
27
+ * Fix Node.js 0.8 compatibility
28
+
29
+ 1.1.0 / 2014-07-08
30
+ ==================
31
+
32
+ * Incorporate URL href-only parse fast-path
33
+
34
+ 1.0.1 / 2014-03-08
35
+ ==================
36
+
37
+ * Add missing `require`
38
+
39
+ 1.0.0 / 2014-03-08
40
+ ==================
41
+
42
+ * Genesis from `connect`
@@ -0,0 +1,24 @@
1
+
2
+ (The MIT License)
3
+
4
+ Copyright (c) 2014 Jonathan Ong <me@jongleberry.com>
5
+ Copyright (c) 2014 Douglas Christopher Wilson <doug@somethingdoug.com>
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.
@@ -0,0 +1,107 @@
1
+ # parseurl
2
+
3
+ [![NPM version](https://badge.fury.io/js/parseurl.svg)](http://badge.fury.io/js/parseurl)
4
+ [![Build Status](https://travis-ci.org/expressjs/parseurl.svg?branch=master)](https://travis-ci.org/expressjs/parseurl)
5
+ [![Coverage Status](https://img.shields.io/coveralls/expressjs/parseurl.svg?branch=master)](https://coveralls.io/r/expressjs/parseurl)
6
+
7
+ Parse a URL with memoization.
8
+
9
+ ## Install
10
+
11
+ ```bash
12
+ $ npm install parseurl
13
+ ```
14
+
15
+ ## API
16
+
17
+ ```js
18
+ var parseurl = require('parseurl')
19
+ ```
20
+
21
+ ### parseurl(req)
22
+
23
+ Parse the URL of the given request object (looks at the `req.url` property)
24
+ and return the result. The result is the same as `url.parse` in Node.js core.
25
+ Calling this function multiple times on the same `req` where `req.url` does
26
+ not change will return a cached parsed object, rather than parsing again.
27
+
28
+ ### parseurl.original(req)
29
+
30
+ Parse the original URL of the given request object and return the result.
31
+ This works by trying to parse `req.originalUrl` if it is a string, otherwise
32
+ parses `req.url`. The result is the same as `url.parse` in Node.js core.
33
+ Calling this function multiple times on the same `req` where `req.originalUrl`
34
+ does not change will return a cached parsed object, rather than parsing again.
35
+
36
+ ## Benchmark
37
+
38
+ ```bash
39
+ $ npm run-script bench
40
+
41
+ > parseurl@1.3.0 bench nodejs-parseurl
42
+ > node benchmark/index.js
43
+
44
+ > node benchmark/fullurl.js
45
+
46
+ Parsing URL "http://localhost:8888/foo/bar?user=tj&pet=fluffy"
47
+
48
+ 1 test completed.
49
+ 2 tests completed.
50
+ 3 tests completed.
51
+
52
+ fasturl x 1,290,780 ops/sec ±0.46% (195 runs sampled)
53
+ nativeurl x 56,401 ops/sec ±0.22% (196 runs sampled)
54
+ parseurl x 55,231 ops/sec ±0.22% (194 runs sampled)
55
+
56
+ > node benchmark/pathquery.js
57
+
58
+ Parsing URL "/foo/bar?user=tj&pet=fluffy"
59
+
60
+ 1 test completed.
61
+ 2 tests completed.
62
+ 3 tests completed.
63
+
64
+ fasturl x 1,986,668 ops/sec ±0.27% (190 runs sampled)
65
+ nativeurl x 98,740 ops/sec ±0.21% (195 runs sampled)
66
+ parseurl x 2,628,171 ops/sec ±0.36% (195 runs sampled)
67
+
68
+ > node benchmark/samerequest.js
69
+
70
+ Parsing URL "/foo/bar?user=tj&pet=fluffy" on same request object
71
+
72
+ 1 test completed.
73
+ 2 tests completed.
74
+ 3 tests completed.
75
+
76
+ fasturl x 2,184,468 ops/sec ±0.40% (194 runs sampled)
77
+ nativeurl x 99,437 ops/sec ±0.71% (194 runs sampled)
78
+ parseurl x 10,498,005 ops/sec ±0.61% (186 runs sampled)
79
+
80
+ > node benchmark/simplepath.js
81
+
82
+ Parsing URL "/foo/bar"
83
+
84
+ 1 test completed.
85
+ 2 tests completed.
86
+ 3 tests completed.
87
+
88
+ fasturl x 4,535,825 ops/sec ±0.27% (191 runs sampled)
89
+ nativeurl x 98,769 ops/sec ±0.54% (191 runs sampled)
90
+ parseurl x 4,164,865 ops/sec ±0.34% (192 runs sampled)
91
+
92
+ > node benchmark/slash.js
93
+
94
+ Parsing URL "/"
95
+
96
+ 1 test completed.
97
+ 2 tests completed.
98
+ 3 tests completed.
99
+
100
+ fasturl x 4,908,405 ops/sec ±0.42% (191 runs sampled)
101
+ nativeurl x 100,945 ops/sec ±0.59% (188 runs sampled)
102
+ parseurl x 4,333,208 ops/sec ±0.27% (194 runs sampled)
103
+ ```
104
+
105
+ ## License
106
+
107
+ [MIT](LICENSE)
@@ -0,0 +1,136 @@
1
+ /*!
2
+ * parseurl
3
+ * Copyright(c) 2014 Jonathan Ong
4
+ * Copyright(c) 2014 Douglas Christopher Wilson
5
+ * MIT Licensed
6
+ */
7
+
8
+ /**
9
+ * Module dependencies.
10
+ */
11
+
12
+ var url = require('url')
13
+ var parse = url.parse
14
+ var Url = url.Url
15
+
16
+ /**
17
+ * Pattern for a simple path case.
18
+ * See: https://github.com/joyent/node/pull/7878
19
+ */
20
+
21
+ var simplePathRegExp = /^(\/\/?(?!\/)[^\?#\s]*)(\?[^#\s]*)?$/
22
+
23
+ /**
24
+ * Exports.
25
+ */
26
+
27
+ module.exports = parseurl
28
+ module.exports.original = originalurl
29
+
30
+ /**
31
+ * Parse the `req` url with memoization.
32
+ *
33
+ * @param {ServerRequest} req
34
+ * @return {Object}
35
+ * @api public
36
+ */
37
+
38
+ function parseurl(req) {
39
+ var url = req.url
40
+
41
+ if (url === undefined) {
42
+ // URL is undefined
43
+ return undefined
44
+ }
45
+
46
+ var parsed = req._parsedUrl
47
+
48
+ if (fresh(url, parsed)) {
49
+ // Return cached URL parse
50
+ return parsed
51
+ }
52
+
53
+ // Parse the URL
54
+ parsed = fastparse(url)
55
+ parsed._raw = url
56
+
57
+ return req._parsedUrl = parsed
58
+ };
59
+
60
+ /**
61
+ * Parse the `req` original url with fallback and memoization.
62
+ *
63
+ * @param {ServerRequest} req
64
+ * @return {Object}
65
+ * @api public
66
+ */
67
+
68
+ function originalurl(req) {
69
+ var url = req.originalUrl
70
+
71
+ if (typeof url !== 'string') {
72
+ // Fallback
73
+ return parseurl(req)
74
+ }
75
+
76
+ var parsed = req._parsedOriginalUrl
77
+
78
+ if (fresh(url, parsed)) {
79
+ // Return cached URL parse
80
+ return parsed
81
+ }
82
+
83
+ // Parse the URL
84
+ parsed = fastparse(url)
85
+ parsed._raw = url
86
+
87
+ return req._parsedOriginalUrl = parsed
88
+ };
89
+
90
+ /**
91
+ * Parse the `str` url with fast-path short-cut.
92
+ *
93
+ * @param {string} str
94
+ * @return {Object}
95
+ * @api private
96
+ */
97
+
98
+ function fastparse(str) {
99
+ // Try fast path regexp
100
+ // See: https://github.com/joyent/node/pull/7878
101
+ var simplePath = typeof str === 'string' && simplePathRegExp.exec(str)
102
+
103
+ // Construct simple URL
104
+ if (simplePath) {
105
+ var pathname = simplePath[1]
106
+ var search = simplePath[2] || null
107
+ var url = Url !== undefined
108
+ ? new Url()
109
+ : {}
110
+ url.path = str
111
+ url.href = str
112
+ url.pathname = pathname
113
+ url.search = search
114
+ url.query = search && search.substr(1)
115
+
116
+ return url
117
+ }
118
+
119
+ return parse(str)
120
+ }
121
+
122
+ /**
123
+ * Determine if parsed is still fresh for url.
124
+ *
125
+ * @param {string} url
126
+ * @param {object} parsedUrl
127
+ * @return {boolean}
128
+ * @api private
129
+ */
130
+
131
+ function fresh(url, parsedUrl) {
132
+ return typeof parsedUrl === 'object'
133
+ && parsedUrl !== null
134
+ && (Url === undefined || parsedUrl instanceof Url)
135
+ && parsedUrl._raw === url
136
+ }
@@ -0,0 +1,80 @@
1
+ {
2
+ "name": "parseurl",
3
+ "description": "parse a url with memoization",
4
+ "version": "1.3.0",
5
+ "author": {
6
+ "name": "Jonathan Ong",
7
+ "email": "me@jongleberry.com",
8
+ "url": "http://jongleberry.com"
9
+ },
10
+ "contributors": [
11
+ {
12
+ "name": "Douglas Christopher Wilson",
13
+ "email": "doug@somethingdoug.com"
14
+ }
15
+ ],
16
+ "repository": {
17
+ "type": "git",
18
+ "url": "git+https://github.com/expressjs/parseurl.git"
19
+ },
20
+ "license": "MIT",
21
+ "devDependencies": {
22
+ "benchmark": "1.0.0",
23
+ "beautify-benchmark": "0.2.4",
24
+ "fast-url-parser": "~1.0.0",
25
+ "istanbul": "0.3.0",
26
+ "mocha": "~1.21.4"
27
+ },
28
+ "scripts": {
29
+ "bench": "node benchmark/index.js",
30
+ "test": "mocha --check-leaks --bail --reporter spec test/",
31
+ "test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --check-leaks --reporter dot test/",
32
+ "test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --check-leaks --reporter spec test/"
33
+ },
34
+ "gitHead": "03b7ccca240e2bef5df6c25797e99175d28fb2cb",
35
+ "bugs": {
36
+ "url": "https://github.com/expressjs/parseurl/issues"
37
+ },
38
+ "homepage": "https://github.com/expressjs/parseurl",
39
+ "_id": "parseurl@1.3.0",
40
+ "_shasum": "b58046db4223e145afa76009e61bac87cc2281b3",
41
+ "_from": "parseurl@>=1.3.0 <1.4.0",
42
+ "_npmVersion": "1.4.21",
43
+ "_npmUser": {
44
+ "name": "dougwilson",
45
+ "email": "doug@somethingdoug.com"
46
+ },
47
+ "maintainers": [
48
+ {
49
+ "name": "jongleberry",
50
+ "email": "jonathanrichardong@gmail.com"
51
+ },
52
+ {
53
+ "name": "shtylman",
54
+ "email": "shtylman@gmail.com"
55
+ },
56
+ {
57
+ "name": "dougwilson",
58
+ "email": "doug@somethingdoug.com"
59
+ },
60
+ {
61
+ "name": "tjholowaychuk",
62
+ "email": "tj@vision-media.ca"
63
+ },
64
+ {
65
+ "name": "mscdex",
66
+ "email": "mscdex@mscdex.net"
67
+ },
68
+ {
69
+ "name": "fishrock123",
70
+ "email": "fishrock123@rocketmail.com"
71
+ }
72
+ ],
73
+ "dist": {
74
+ "shasum": "b58046db4223e145afa76009e61bac87cc2281b3",
75
+ "tarball": "http://registry.npmjs.org/parseurl/-/parseurl-1.3.0.tgz"
76
+ },
77
+ "directories": {},
78
+ "_resolved": "http://registry.npmjs.org/parseurl/-/parseurl-1.3.0.tgz",
79
+ "readme": "ERROR: No README data found!"
80
+ }
@@ -0,0 +1,36 @@
1
+ 0.1.7 / 2015-07-28
2
+ ==================
3
+
4
+ * Fixed regression with escaped round brackets and matching groups.
5
+
6
+ 0.1.6 / 2015-06-19
7
+ ==================
8
+
9
+ * Replace `index` feature by outputting all parameters, unnamed and named.
10
+
11
+ 0.1.5 / 2015-05-08
12
+ ==================
13
+
14
+ * Add an index property for position in match result.
15
+
16
+ 0.1.4 / 2015-03-05
17
+ ==================
18
+
19
+ * Add license information
20
+
21
+ 0.1.3 / 2014-07-06
22
+ ==================
23
+
24
+ * Better array support
25
+ * Improved support for trailing slash in non-ending mode
26
+
27
+ 0.1.0 / 2014-03-06
28
+ ==================
29
+
30
+ * add options.end
31
+
32
+ 0.0.2 / 2013-02-10
33
+ ==================
34
+
35
+ * Update to match current express
36
+ * add .license property to component.json
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2014 Blake Embrey (hello@blakeembrey.com)
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
13
+ all 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
21
+ THE SOFTWARE.