diff --git a/docs/release-notes.md b/docs/release-notes.md new file mode 100644 index 00000000..1d0aa534 --- /dev/null +++ b/docs/release-notes.md @@ -0,0 +1,32 @@ +## 0.6.0 + +### request.path_params + +The biggest change here is that endpoint signatures are no longer: + +```python +async def func(request: Request, **kwargs) -> Response +``` + +Instead we just use: + +```python +async def func(request: Request) -> Response +``` + +The path parameters are available on the request as `request.path_params`. + +This is different to most Python webframeworks, but I think it actually ends up +being much more nicely consistent all the way through. + +### app.url_for(name, **path_params) + +Applications now support URL reversing with `app.url_for(name, **path_params)`. + +### app.routes + +Applications now support a `.routes` parameter, which returns a list of `[Route|WebSocketRoute|Mount]`. + +### Route, WebSocketRoute, Mount + +The low level components to `Router` now match the `@app.route()`, `@app.websocket_route()`, and `app.mount()` signatures. diff --git a/mkdocs.yml b/mkdocs.yml index 1b687809..42cf8270 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -24,6 +24,7 @@ nav: - Exceptions: 'exceptions.md' - Debug: 'debug.md' - Test Client: 'testclient.md' + - Release Notes: 'release-notes.md' markdown_extensions: - markdown.extensions.codehilite: