Serve JavaScript modules via Django static files
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 25/100
- Tipo di issue
- Funzionalità
- Chiarezza
- Abbastanza chiara
- Stato di attività
- Ferma
- Stack tecnologico
- django, javascript, python, react
Direzione di ricerca
Start by reviewing Django's STATICFILES_FINDERS documentation and the original issue #4, then compare the proposed finder, collect_modules, and explicit-folder approaches. Done means selecting and implementing a deterministic integration that serves ReactPy JavaScript modules through Django's static-file system, with an explicit behavior for modules missing at startup.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Current Situation
Currently, we serve our JavaScript web modules (JavaScript Components) via views. This is due to the fact that our current architecture does not let us know what web modules exist until runtime.
However, Django views are less efficient at serving files than a webserver such as Nginx or Apache.
Proposed Actions
Develop a way of integrating with the Django Static File system.
Work Items
We have a couple of paths we could take
- Create a static file finder that points to ReactPy's web modules directory
- This is the preferred implementation if feasible
- Develop a
collect_modulescommand, similar to django-compressor'scollect_staticcommand- This option requires changes in ReactPy to deterministically collect all JavaScript web modules during startup.
- Also, what should we do if we accidentally did not obtain a static file during startup? Should we fallback to using our Django view, or just throw a
404 Not Founderror?
- Make users put JavaScript modules in dedicated
JAVASCRIPT_MODULES = [ ... ]folder(s)- User's will need to statically define their ReactPy JavaScript modules with this method.
See #4 for the original issue.
- Lingua principale
- Python
- Stelle
- 357
- Fork
- 22
- Merge medio
- 10h 31m
- PR unite (30g)
- 2
Guida per i contributori
Nessuna guida per i contributori indicizzata per questo repository
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di reactive-python/reactpy-django
-
Add coverage tests Apertacomplexity: 3 (low) priority: 3 (low) type: ci
Difficoltà 3/5 1-2 giorni Idoneità per principianti 45/100
-
complexity: 1 (high) priority: 1 (high)
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
-
complexity: 2 (medium) priority: 3 (low)
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
-
complexity: 2 (medium) priority: 3 (low)
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
-
`pyscript_router` component Apertacomplexity: 1 (high) priority: 2 (moderate)
Difficoltà 5/5 Più di una settimana Idoneità per principianti 25/100
Tutte le issue di reactive-python/reactpy-django
Issue simili
-
link-check link-check:sphinx-theme
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 65/100
qgis/QGIS-Documentation#11275 ·
-
bug priority:normal ready-for-dev
Difficoltà 2/5 1-3 ore Idoneità per principianti 88/100
OpenHands/extensions#626 · 1 commento ·
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 90/100
CSCfi/sd-search-api#39 ·
-
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 90/100