I have an API to keep watching database for changes and updates the same to Django. And am using Django channels to update the changes to the front end templates as well. I am running the API along with Django run server and gets changes from database and API runs indefinitely.
The problem is though API keeps watching the changes which never terminates Django is not able to get the http request so webpage is not loading.
I need to run API when Django starts as well as web page should be loaded and for every 1 second will update the web page with the new changes.
But now when I start the API along with Django am not able to load the webpage because API is infinite.
How do I do this in order to load webpage and start updating changes to the webpage ?
question from:
https://stackoverflow.com/questions/65936134/how-to-load-django-template-async 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…