Which do you prefer and why.
For further actions, you may consider blocking this person and/or reporting abuse
Which do you prefer and why.
For further actions, you may consider blocking this person and/or reporting abuse
Ethan Lee -
Hana Sato -
Evotik -
Gabrielle Niamat -
Top comments (4)
I think the use cases for them are pretty different, but both are great!
If you are building something minimalistic or without a database, Flask is much easier to get up and running. If you are doing anything larger with complex database relationships, auth, or want the admin interface -- Django does each so gracefully.
Both Django & Flask are great and both can do the job for you.
From my experience, I've found that:
Flask is minimalist framework & Django is not a "fat framework".
For me, learning Django has long term benefits, because the abstraction is great & the libraries for things like "Rest APIs" are also great. It's more suitable for large projects that will scale with time.
On the other hand, I find Flask to be the right tool when I want to expose some kind of Python on the web (with AWS Lambda for example). Then the 1 file approach works great for me.
And if you like the minimalist approach & you like building your own abstraction & using different tools for the job, Flask will be just as great as Django, but perhaps it's going to require more time & investment on your side.
And on the high level, for me, that's pretty much it 👍
That pretty much answers it. I always knew that Flask was he lightweight framework while Django was batteries included but that was very detailed. Thanks.
For a beginner like me I tried to do sample projects with both flask and django. For me I liked flask more because it allowed me to build up the parts to learn about the interactions. For example implementing databases with sqlalchemy. Django had too much automagic going on to really understand why it was the way it was. Hope this helps other beginners!