Add ?json support

This commit is contained in:
Michael Jackson 2016-05-24 18:07:46 -07:00
parent c1c2805f40
commit f4c1f7f338
2 changed files with 6 additions and 1 deletions

View File

@ -46,6 +46,11 @@ You may use the special `/bower.zip` file path in packages that contain a `bower
<td>`main`</td> <td>`main`</td>
<td>The name of the field in [package.json](https://docs.npmjs.com/files/package.json) to use as the main entry point when there is no file path in the URL (e.g. `?main=browser`).</td> <td>The name of the field in [package.json](https://docs.npmjs.com/files/package.json) to use as the main entry point when there is no file path in the URL (e.g. `?main=browser`).</td>
</tr> </tr>
<tr>
<td>`json`</td>
<td>`undefined`</td>
<td>Return metadata about the resource at the current URL as JSON (e.g. `/any/path?json`). For directories, this generates a recursive listing of all files in the directory.</td>
</tr>
</tbody> </tbody>
</table> </table>

View File

@ -32,7 +32,7 @@
"json-loader": "^0.5.4", "json-loader": "^0.5.4",
"markdown-loader": "^0.1.7", "markdown-loader": "^0.1.7",
"morgan": "^1.7.0", "morgan": "^1.7.0",
"npm-http-server": "^2.13.1", "npm-http-server": "^2.14.0",
"on-finished": "^2.3.0", "on-finished": "^2.3.0",
"postcss-loader": "^0.9.1", "postcss-loader": "^0.9.1",
"react": "^15.0.2", "react": "^15.0.2",