We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3d777ba commit 03030c5Copy full SHA for 03030c5
pattern_library/monkey_utils.py
@@ -1,5 +1,7 @@
1
import logging
2
+from typing import Optional
3
4
+import django
5
from django.template.library import SimpleNode
6
7
from pattern_library.utils import is_pattern_library_context, render_pattern
@@ -8,11 +10,11 @@
8
10
UNSPECIFIED = object()
9
11
12
-def override_tag(register, name, default_html=None):
13
+def override_tag(
14
+ register: django.template.Library, name: str, default_html: Optional[str] = None
15
+):
16
"""
17
An utility that helps you override original tags for use in your pattern library.
-
- Accepts the register argument which should be an instance of django.template.Library.
18
19
20
original_tag = register.tags[name]
pattern_library/py.typed
0 commit comments