Last active
July 17, 2021 17:49
-
-
Save faulander/008fffb4236ebbf7d2cb9b6806950efa to your computer and use it in GitHub Desktop.
[Include htmx in Django Webpages] #htmx #django #python
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<script> | |
document.body.addEventListener('htmx:configRequest', (event) => { | |
event.detail.headers['X-CSRFToken'] = '{{ csrf_token }}'; | |
}) | |
</script> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment