feat: add template rendering support with context variable injection
This commit is contained in:
parent
fa3a53a6d7
commit
3270bf85c2
@ -106,8 +106,8 @@ class BaseApplication(RPCApplication):
|
||||
|
||||
return await handler(request)
|
||||
|
||||
async def render_template(self, name, request, context):
|
||||
return aiohttp_jinja2.render_template(name, self.request, context)
|
||||
async def render_template(self, name, request=None, context=None):
|
||||
return aiohttp_jinja2.render_template(name, request, context)
|
||||
|
||||
@web.middleware
|
||||
async def request_middleware(self, request: web.Request, handler):
|
||||
|
||||
Loading…
Reference in New Issue
Block a user