mirror of
https://github.com/jointakahe/takahe.git
synced 2024-11-25 16:51:00 +00:00
9c424d9bb6
Refs #33
11 lines
279 B
Python
11 lines
279 B
Python
from typing import Optional
|
|
|
|
|
|
class HTMXMixin:
|
|
template_name_htmx: Optional[str] = None
|
|
|
|
def get_template_name(self):
|
|
if self.request.htmx and self.template_name_htmx:
|
|
return self.template_name_htmx
|
|
else:
|
|
return self.template_name
|