Template Tags
Django template tags for the DropZone react app.
- smarter.apps.dashboard.templatetags.react_dropzone.dropzone_react_assets()[source]
Load CSS and JS files for a React app entry point.
based on its manifest.json.
- Return type:
AssetDict
- smarter.apps.dashboard.templatetags.react_dropzone.templatetag_manager = <smarter.lib.django.templatetags.smarter_react_templatetag_manager.SmarterReactTemplateTagManager object>
Manages integration of Vite-built React assets into Django templates.
Expects to find a Vite-generated manifest.json in the file path static/react/@smarter/drop-zone/.
Example manifest.json structure:
{ "index.html": { "file": "assets/index-D6-GPOR-.js", "name": "index", "src": "index.html", "isEntry": true, "css": [ "assets/index-B011HLqe.css" ] } }