feat: extension defaults + docs + API cleanup (#1215)

This commit is contained in:
Juro Oravec 2025-05-26 23:36:19 +02:00 committed by GitHub
parent 7df8019544
commit bb129aefab
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
16 changed files with 858 additions and 144 deletions

View file

@ -19,6 +19,10 @@
options:
show_if_no_docstring: true
::: django_components.ComponentDebugHighlight
options:
show_if_no_docstring: true
::: django_components.ComponentDefaults
options:
show_if_no_docstring: true
@ -75,6 +79,10 @@
options:
show_if_no_docstring: true
::: django_components.ExtensionComponentConfig
options:
show_if_no_docstring: true
::: django_components.RegistrySettings
options:
show_if_no_docstring: true

View file

@ -43,6 +43,7 @@ defaults = ComponentsSettings(
debug_highlight_slots=False,
dynamic_component_name="dynamic",
extensions=[],
extensions_defaults={},
libraries=[], # E.g. ["mysite.components.forms", ...]
multiline_tags=True,
reload_on_file_change=False,
@ -157,6 +158,16 @@ defaults = ComponentsSettings(
show_if_no_docstring: true
show_labels: false
::: django_components.app_settings.ComponentsSettings.extensions_defaults
options:
show_root_heading: true
show_signature: true
separate_signature: true
show_symbol_type_heading: false
show_symbol_type_toc: false
show_if_no_docstring: true
show_labels: false
::: django_components.app_settings.ComponentsSettings.forbidden_static_files
options:
show_root_heading: true

View file

@ -67,7 +67,7 @@ If you insert this tag multiple times, ALL JS scripts will be duplicately insert
<a href="https://github.com/django-components/django-components/tree/master/src/django_components/templatetags/component_tags.py#L3164" target="_blank">See source code</a>
<a href="https://github.com/django-components/django-components/tree/master/src/django_components/templatetags/component_tags.py#L3172" target="_blank">See source code</a>
@ -169,7 +169,7 @@ COMPONENTS = {
<a href="https://github.com/django-components/django-components/tree/master/src/django_components/templatetags/component_tags.py#L949" target="_blank">See source code</a>
<a href="https://github.com/django-components/django-components/tree/master/src/django_components/templatetags/component_tags.py#L948" target="_blank">See source code</a>
@ -467,7 +467,7 @@ user = self.inject("user_data")["user"]
<a href="https://github.com/django-components/django-components/tree/master/src/django_components/templatetags/component_tags.py#L475" target="_blank">See source code</a>
<a href="https://github.com/django-components/django-components/tree/master/src/django_components/templatetags/component_tags.py#L474" target="_blank">See source code</a>