What does include() in urls.py do in django?
I am new to django. I came across the
include() method. I read the documentation regarding it. But couldn’t understand it as it lacked suitable examples. I am again rewriting this question in a proper way so that it doesn’t sound baseless. Can someone please help me out by giving me a suitable example regarding the scenario in which the
include() method becomes handy?
include() adds urls from your app directory’s
urls.py to the main urls.py (in memory). This keeps the main urls.py from getting too big to read.
The Including Other URLConfs section.
Answered By – Tony Dare