This file contains 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
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE | |
Version 2, December 2004 | |
Copyright (C) 2011 Denis Ciccale <http://webdecs.wordpress.com> | |
Everyone is permitted to copy and distribute verbatim or modified | |
copies of this license document, and changing it is allowed as long | |
as the name is changed. | |
DO WHAT THE FUCK YOU WANT TO PUBLIC LICENSE |
- Website: https://stimulusjs.org/
- GitHub repo: https://github.com/stimulusjs/stimulus
- Handbook: https://stimulusjs.org/handbook/introduction
- Discourse: https://discourse.stimulusjs.org/
initialize
: once, when the controller is first instantiatedconnect
: anytime the controller is connected to the DOM
NB: the whole approach of serving a Vue project through Django is less than ideal, so this can be seen as deprecated.
The goal of this gist is to be able to use the built-in makemessages
command of Django on your Vue frontend. You can then expose a JavaScript catalog and localize your frontend using gettext
.
Following assumptions are made:
- The directory for the frontend lives in your Django project
- You are using components (.vue files)
Somewhere in urls.py
: