diff options
Diffstat (limited to '')
| -rw-r--r-- | pydis_site/apps/content/templatetags/page_src.py | 5 | 
1 files changed, 5 insertions, 0 deletions
diff --git a/pydis_site/apps/content/templatetags/page_src.py b/pydis_site/apps/content/templatetags/page_src.py index 261abbdf..143c420c 100644 --- a/pydis_site/apps/content/templatetags/page_src.py +++ b/pydis_site/apps/content/templatetags/page_src.py @@ -12,6 +12,11 @@ def page_src_url(request_path: str) -> str:      request_path is the relative path of an article, as returned by `request.path` in templates. +    GitHub source URL is set in settings.py as CONTENT_SRC_URL, prefix for the +    url which the request path would be appended to. + +    Assumes '.md' file extension for the page source files. +      For example: /pages/rules/ would return:      https://github.com/python-discord/site/tree/main/pydis_site/apps/content/resources/rules.md      """  |