[Answer]-Django – should I use only 1 view for all website?

1👍

You can do one view, but if it starts to get complex, accounting for each possible input and output can become a headache. I suggest you use as many views as you need and then later implement AJAX to present everything as if it’s only one-page

👤yuvi

0👍

Seems like if that is the only thing that you want to do, having one FormView and handling the cases accordingly should suffice. For a given form, if it’s not necessary, keeping it to one view is generally a good choice.

Leave a comment