Let's say I have a a hybrid application (the django templater is required to serve the page with the form widgets, data, etc, however there is still a decent amount of js/ejs/lodash/etc wizardry going on in the front-end).

The front-end engineers would prefer to develop on npm's purpose-built front-end dev server, but need the output from the django templater. What is the correct way to simulate a browser request, and direct the page body to stdout (to be picked up by webpack or whatever else is going on in the front-end dev environment)?

Should I manage.py runserver, and simulate a request with curl? Or is there a better way? It strikes me as difficult to manage authentication and csrf this way.

0

There are 0 best solutions below