Skip to content

Commit 9b7e53d

Browse files
author
github-actions
committed
Deployed 50c26e4 to develop with MkDocs 1.6.1 and mike 2.1.3
1 parent df83ac4 commit 9b7e53d

File tree

11 files changed

+253
-251
lines changed

11 files changed

+253
-251
lines changed

develop/assets/css/home.css

Lines changed: 238 additions & 236 deletions
Large diffs are not rendered by default.
703 Bytes
Loading
46 Bytes
Loading
Loading

develop/reference/components/index.html

Lines changed: 2 additions & 2 deletions
Large diffs are not rendered by default.

develop/reference/decorators/index.html

Lines changed: 2 additions & 2 deletions
Large diffs are not rendered by default.

develop/reference/hooks/index.html

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -876,7 +876,7 @@
876876
<span class=n>use_channel_layer</span><span class=p>(</span><span class=n>group_name</span><span class=o>=</span><span class=s2>&quot;my-group-name&quot;</span><span class=p>,</span> <span class=n>receiver</span><span class=o>=</span><span class=n>receive_event</span><span class=p>)</span>
877877

878878
<span class=k>return</span> <span class=n>html</span><span class=o>.</span><span class=n>div</span><span class=p>(</span><span class=sa>f</span><span class=s2>&quot;Message Receiver 2: </span><span class=si>{</span><span class=n>message</span><span class=si>}</span><span class=s2>&quot;</span><span class=p>)</span>
879-
</code></pre></div></td></tr></table></div> </div> </div> </div> </details> <details class=question> <summary>How do I signal a re-render from something that isn't a component?</summary> <p>There are occasions where you may want to signal a re-render from something that isn't a component, such as a Django model signal.</p> <p>In these cases, you can use the <code class=highlight><span class=n>use_channel_layer</span></code> hook to receive a signal within your component, and then use the <code class=highlight><span class=n>get_channel_layer</span><span class=p>()</span><span class=o>.</span><span class=n>send</span><span class=p>(</span><span class=o>...</span><span class=p>)</span></code> to send the signal.</p> <p>In the example below, the sender will send a signal every time <code class=highlight><span class=n>ExampleModel</span></code> is saved. Then, when the receiver component gets this signal, it explicitly calls <code class=highlight><span class=n>set_message</span><span class=p>(</span><span class=o>...</span><span class=p>)</span></code> to trigger a re-render.</p> <div class="tabbed-set tabbed-alternate" data-tabs=17:2><input checked=checked id=__tabbed_17_1 name=__tabbed_17 type=radio><input id=__tabbed_17_2 name=__tabbed_17 type=radio><div class=tabbed-labels><label for=__tabbed_17_1>signals.py</label><label for=__tabbed_17_2>components.py</label></div> <div class=tabbed-content> <div class=tabbed-block> <div class=highlight><table class=highlighttable><tr><td class=linenos><div class=linenodiv><pre><span></span><span class=normal> 1</span>
879+
</code></pre></div></td></tr></table></div> </div> </div> </div> </details> <details class=question> <summary>How do I signal a re-render from something that isn't a component?</summary> <p>There are occasions where you may want to signal a re-render from something that isn't a component, such as a Django model signal.</p> <p>In these cases, you can use the <code class=highlight><span class=n>use_channel_layer</span></code> hook to receive a signal within your component, and then use the <code class=highlight><span class=n>get_channel_layer</span><span class=p>()</span><span class=o>.</span><span class=n>send</span><span class=p>(</span><span class=o>...</span><span class=p>)</span></code> to send the signal.</p> <p>In the example below, the sender will signal every time <code class=highlight><span class=n>ExampleModel</span></code> is saved. Then, when the receiver gets this signal, it explicitly calls <code class=highlight><span class=n>set_message</span><span class=p>(</span><span class=o>...</span><span class=p>)</span></code> to trigger a re-render.</p> <div class="tabbed-set tabbed-alternate" data-tabs=17:2><input checked=checked id=__tabbed_17_1 name=__tabbed_17 type=radio><input id=__tabbed_17_2 name=__tabbed_17 type=radio><div class=tabbed-labels><label for=__tabbed_17_1>signals.py</label><label for=__tabbed_17_2>components.py</label></div> <div class=tabbed-content> <div class=tabbed-block> <div class=highlight><table class=highlighttable><tr><td class=linenos><div class=linenodiv><pre><span></span><span class=normal> 1</span>
880880
<span class=normal> 2</span>
881881
<span class=normal> 3</span>
882882
<span class=normal> 4</span>
@@ -1008,7 +1008,7 @@
10081008
<span class=n>origin</span> <span class=o>=</span> <span class=n>use_origin</span><span class=p>()</span>
10091009

10101010
<span class=k>return</span> <span class=n>html</span><span class=o>.</span><span class=n>div</span><span class=p>(</span><span class=n>origin</span> <span class=ow>or</span> <span class=s2>&quot;No origin&quot;</span><span class=p>)</span>
1011-
</code></pre></div></td></tr></table></div> </div> </div> </div> <details class=example> <summary>See Interface</summary> <p><font size=4><strong>Parameters</strong></font></p> <p><code class=highlight><span class=kc>None</span></code></p> <p><font size=4><strong>Returns</strong></font></p> <table> <thead> <tr> <th>Type</th> <th>Description</th> </tr> </thead> <tbody> <tr> <td><code class=highlight><span class=nb>str</span> <span class=o>|</span> <span class=kc>None</span></code></td> <td>A string containing the browser's current origin, obtained from WebSocket or HTTP headers (if available).</td> </tr> </tbody> </table> </details> <hr> <h3 id=use-root-id>Use Root ID<a class=headerlink href=#use-root-id title="Permanent link">&para;</a></h3> <p>Shortcut that returns the root component's <code class=highlight><span class=nb>id</span></code> from the WebSocket or HTTP connection.</p> <p>The root ID is currently a randomly generated <code class=highlight><span class=n>uuid4</span></code> (unique across all root component).</p> <p>This is useful when used in combination with <a href=#use-channel-layer><code class=highlight><span class=n>use_channel_layer</span></code></a> to send messages to a specific component instance, and/or retain a backlog of messages in case that component is disconnected via <code class=highlight><span class=n>use_channel_layer</span><span class=p>(</span> <span class=o>...</span> <span class=p>,</span> <span class=n>group_discard</span><span class=o>=</span><span class=kc>False</span><span class=p>)</span></code>.</p> <div class="tabbed-set tabbed-alternate" data-tabs=22:1><input checked=checked id=__tabbed_22_1 name=__tabbed_22 type=radio><div class=tabbed-labels><label for=__tabbed_22_1>components.py</label></div> <div class=tabbed-content> <div class=tabbed-block> <div class=highlight><table class=highlighttable><tr><td class=linenos><div class=linenodiv><pre><span></span><span class=normal>1</span>
1011+
</code></pre></div></td></tr></table></div> </div> </div> </div> <details class=example> <summary>See Interface</summary> <p><font size=4><strong>Parameters</strong></font></p> <p><code class=highlight><span class=kc>None</span></code></p> <p><font size=4><strong>Returns</strong></font></p> <table> <thead> <tr> <th>Type</th> <th>Description</th> </tr> </thead> <tbody> <tr> <td><code class=highlight><span class=nb>str</span> <span class=o>|</span> <span class=kc>None</span></code></td> <td>A string containing the browser's current origin, obtained from WebSocket or HTTP headers (if available).</td> </tr> </tbody> </table> </details> <hr> <h3 id=use-root-id>Use Root ID<a class=headerlink href=#use-root-id title="Permanent link">&para;</a></h3> <p>Shortcut that returns the root component's <code class=highlight><span class=nb>id</span></code> from the WebSocket or HTTP connection.</p> <p>The root ID is a randomly generated <code class=highlight><span class=n>uuid4</span></code>. It is notable to mention that it is persistent across the current connection. The <code>uuid</code> is reset when the page is refreshed.</p> <p>This is useful when used in combination with <a href=#use-channel-layer><code class=highlight><span class=n>use_channel_layer</span></code></a> to send messages to a specific component instance, and/or retain a backlog of messages in case that component is disconnected via <code class=highlight><span class=n>use_channel_layer</span><span class=p>(</span> <span class=o>...</span> <span class=p>,</span> <span class=n>group_discard</span><span class=o>=</span><span class=kc>False</span><span class=p>)</span></code>.</p> <div class="tabbed-set tabbed-alternate" data-tabs=22:1><input checked=checked id=__tabbed_22_1 name=__tabbed_22 type=radio><div class=tabbed-labels><label for=__tabbed_22_1>components.py</label></div> <div class=tabbed-content> <div class=tabbed-block> <div class=highlight><table class=highlighttable><tr><td class=linenos><div class=linenodiv><pre><span></span><span class=normal>1</span>
10121012
<span class=normal>2</span>
10131013
<span class=normal>3</span>
10141014
<span class=normal>4</span>
@@ -1042,4 +1042,4 @@
10421042
<span class=n>user</span> <span class=o>=</span> <span class=n>use_user</span><span class=p>()</span>
10431043

10441044
<span class=k>return</span> <span class=n>html</span><span class=o>.</span><span class=n>div</span><span class=p>(</span><span class=n>user</span><span class=o>.</span><span class=n>username</span><span class=p>)</span>
1045-
</code></pre></div></td></tr></table></div> </div> </div> </div> <details class=example> <summary>See Interface</summary> <p><font size=4><strong>Parameters</strong></font></p> <p><code class=highlight><span class=kc>None</span></code></p> <p><font size=4><strong>Returns</strong></font></p> <table> <thead> <tr> <th>Type</th> <th>Description</th> </tr> </thead> <tbody> <tr> <td><code class=highlight><span class=n>AbstractUser</span></code></td> <td>A Django <code class=highlight><span class=n>User</span></code>, which can also be an <code class=highlight><span class=n>AnonymousUser</span></code>.</td> </tr> </tbody> </table> </details> <hr> <div class=md-source-file> <small> Last update: <span class="git-revision-date-localized-plugin git-revision-date-localized-plugin-date">June 19, 2024</span> </small> </div> <div class=md-source-date> <small> Authors: <span class="git-page-authors git-authors"><a href=mailto:archiethemonger@gmail.com>Mark Bakhit</a></span> </small> </div> </article> </div> </div> <button type=button class="md-top md-icon" data-md-component=top hidden> <svg xmlns=http://www.w3.org/2000/svg viewbox="0 0 24 24"><path d="M13 20h-2V8l-5.5 5.5-1.42-1.42L12 4.16l7.92 7.92-1.42 1.42L13 8v12Z"/></svg> Back to top </button> </main> <footer class=md-footer> <div class="md-footer-meta md-typeset"> <div class="md-footer-meta__inner md-grid"> <div class=md-copyright> <div class=md-copyright__highlight> &copy; <div id=year></div> <script>document.getElementById("year").innerHTML = new Date().getFullYear();</script> Reactive Python and affiliates. <div class=legal-footer-right>This project has no affiliation to ReactJS or Meta Platforms, Inc.</div> </div> </div> </div> </div> </footer> </div> <div class=md-dialog data-md-component=dialog> <div class="md-dialog__inner md-typeset"></div> </div> <script id=__config type=application/json>{"base": "../..", "features": ["navigation.instant", "navigation.tabs", "navigation.tabs.sticky", "navigation.top", "content.code.copy", "search.highlight"], "search": "../../assets/javascripts/workers/search.a264c092.min.js", "translations": {"clipboard.copied": "Copied to clipboard", "clipboard.copy": "Copy to clipboard", "search.result.more.one": "1 more on this page", "search.result.more.other": "# more on this page", "search.result.none": "No matching documents", "search.result.one": "1 matching document", "search.result.other": "# matching documents", "search.result.placeholder": "Type to start searching", "search.result.term.missing": "Missing", "select.version": "Select version"}, "version": {"provider": "mike"}}</script> <script src=../../assets/javascripts/bundle.4e0fa4ba.min.js></script> <script src=../../assets/js/main.js></script> </body> </html>
1045+
</code></pre></div></td></tr></table></div> </div> </div> </div> <details class=example> <summary>See Interface</summary> <p><font size=4><strong>Parameters</strong></font></p> <p><code class=highlight><span class=kc>None</span></code></p> <p><font size=4><strong>Returns</strong></font></p> <table> <thead> <tr> <th>Type</th> <th>Description</th> </tr> </thead> <tbody> <tr> <td><code class=highlight><span class=n>AbstractUser</span></code></td> <td>A Django <code class=highlight><span class=n>User</span></code>, which can also be an <code class=highlight><span class=n>AnonymousUser</span></code>.</td> </tr> </tbody> </table> </details> <hr> <div class=md-source-file> <small> Last update: <span class="git-revision-date-localized-plugin git-revision-date-localized-plugin-date">September 24, 2024</span> </small> </div> <div class=md-source-date> <small> Authors: <span class="git-page-authors git-authors"><a href=mailto:archiethemonger@gmail.com>Mark Bakhit</a></span> </small> </div> </article> </div> </div> <button type=button class="md-top md-icon" data-md-component=top hidden> <svg xmlns=http://www.w3.org/2000/svg viewbox="0 0 24 24"><path d="M13 20h-2V8l-5.5 5.5-1.42-1.42L12 4.16l7.92 7.92-1.42 1.42L13 8v12Z"/></svg> Back to top </button> </main> <footer class=md-footer> <div class="md-footer-meta md-typeset"> <div class="md-footer-meta__inner md-grid"> <div class=md-copyright> <div class=md-copyright__highlight> &copy; <div id=year></div> <script>document.getElementById("year").innerHTML = new Date().getFullYear();</script> Reactive Python and affiliates. <div class=legal-footer-right>This project has no affiliation to ReactJS or Meta Platforms, Inc.</div> </div> </div> </div> </div> </footer> </div> <div class=md-dialog data-md-component=dialog> <div class="md-dialog__inner md-typeset"></div> </div> <script id=__config type=application/json>{"base": "../..", "features": ["navigation.instant", "navigation.tabs", "navigation.tabs.sticky", "navigation.top", "content.code.copy", "search.highlight"], "search": "../../assets/javascripts/workers/search.a264c092.min.js", "translations": {"clipboard.copied": "Copied to clipboard", "clipboard.copy": "Copy to clipboard", "search.result.more.one": "1 more on this page", "search.result.more.other": "# more on this page", "search.result.none": "No matching documents", "search.result.one": "1 matching document", "search.result.other": "# matching documents", "search.result.placeholder": "Type to start searching", "search.result.term.missing": "Missing", "select.version": "Select version"}, "version": {"provider": "mike"}}</script> <script src=../../assets/javascripts/bundle.4e0fa4ba.min.js></script> <script src=../../assets/js/main.js></script> </body> </html>

develop/reference/html/index.html

Lines changed: 2 additions & 2 deletions
Large diffs are not rendered by default.

develop/reference/template-tag/index.html

Lines changed: 3 additions & 3 deletions
Large diffs are not rendered by default.

develop/reference/utils/index.html

Lines changed: 2 additions & 2 deletions
Large diffs are not rendered by default.

develop/search/search_index.json

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)