register_routes() plugin hook (#819)

Fixes #215
This commit is contained in:
Simon Willison 2020-06-08 20:12:06 -07:00 committed by GitHub
commit f5e79adf26
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
9 changed files with 129 additions and 4 deletions

View file

@ -60,6 +60,11 @@ def register_facet_classes():
"Register Facet subclasses"
@hookspec
def register_routes():
"Register URL routes: return a list of (regex, view_function) pairs"
@hookspec
def actor_from_request(datasette, request):
"Return an actor dictionary based on the incoming request"