Why I Picked Django for Web Development?
The Time I Started Developing Web Applications
In 2014, I found myself increasingly fascinated by how web applications function. This curiosity emerged just as tech startups were beginning to gain significant traction across various industries, including healthcare.
At that time, I was working as a nursing informaticist in a tertiary hospital in the Philippines. My journey into software development began with no prior experience, and I had minimal access to mentors who could guide me through the complexities of software engineering.
Fortunately, my role as a nursing informaticist involved projects that required system analysis and design, user acceptance testing, and end-user training. Through these experiences, I gained some technical skills in software development by managing projects and collaborating with IT professionals.
However, this exposure was not enough to feed my curiosity about web development. Determined to learn more, I began teaching myself to code in my free time, dedicating evenings and weekends to expanding my knowledge.
My First Attempt to Develop a Full-Featured Web Application
As part of my learning journey, I set out to create a social networking web application for nurses. This project evolved through many iterations and eventually became diversees.com—a platform for communities of practice.
I started by learning HTML, CSS, JavaScript, SQL, and PHP, all without the aid of frameworks. My first year was challenging, to say the least. I was manually maintaining my own CSS classes, using jQuery without fully understanding JavaScript, connecting directly to the database with plain PHP, and running queries with raw SQL.
Coming from a non-technical background, I wrote a lot of code just to accomplish simple tasks. I didn’t even know how to properly structure my directories or organize my files. Everything was done manually, and the system’s security was highly vulnerable. Eventually, someone advised me to use a web framework, and that was a turning point.
I realized that the web had been evolving for decades, and experienced developers had already streamlined many development tasks, addressed security concerns, and encapsulated these solutions within web frameworks. Although my starting point was far from ideal, it gave me a deep appreciation for the hard work of the core developers behind these frameworks.
My Initial Impression Working with Django
In 2019, I began learning Django with version 2.0.13, and simultaneously, I started learning Python by following the official Django tutorial. To be honest, it wasn’t an enjoyable experience. The Django documentation wasn’t very beginner-friendly, and the learning curve was steep.
At times, it was so challenging that I almost considered switching to another framework or giving up entirely. Thankfully, some generous individuals had already created resources to make the learning process less painful. I owe much of my progress to the work of William Vincent, Vitor Freitas, and Daniel Roy Greenfield, whose contributions made a significant difference.
After months of studying Django, I began to appreciate the structural design and philosophy behind it. For someone without a technical background, diving into Django can be a real test of your commitment to learning the framework.
In my experience, it challenges how much effort you're willing to invest. However, once you push through that initial learning curve, developing a web application becomes significantly easier. With that in mind, I’d like to share some of the reasons why I chose Django despite its steep learning curve.
Reasons for Choosing Django for Web Development:
1. Django is Written in Python.
As both an informaticist and data scientist, much of my work revolves around languages like Python, R, and SQL, which are specifically designed for data-related tasks. Given this, I’ve invested significant time in mastering Python for informatics and data science.
Python is my go-to tool for tasks like data collection, cleaning, analysis, and visualization. Naturally, as a data professional with a strong background in Python, choosing Django as my web application framework made perfect sense—I didn’t need to learn another language to start building web applications.
2. Django Comes with "Batteries Included."
Django comes with a wide array of built-in tools that address many common web development challenges. Before searching for third-party packages, it’s worth exploring the Django documentation because it has already done much of the heavy lifting for you.
Think of Django as a basket filled with various ingredients—like authentication, permissions, sitemaps, and more—and you, the developer, are the chef who combines these ingredients to create a dish (your app). Because Django is packed with features, it’s particularly well-suited for projects with complex system requirements.
3. Django Takes Application Security Seriously
Years ago, as someone with limited technical knowledge about web security, I was unfamiliar with various security threats. However, reading through the Django documentation introduced me to important concepts like SQL injection, cross-site scripting (XSS), cross-site request forgery (CSRF), and clickjacking.
Django is designed with built-in security features that address these vulnerabilities directly. In essence, Django prioritizes security, helping developers avoid many common pitfalls. It includes a robust user authentication system that securely manages user accounts and passwords, further enhancing its security capabilities.
4. Django is Battle-Tested
One of the main reasons I chose to specialize in Django is its proven ability to scale efficiently and handle high traffic demands. Django has demonstrated its robustness by powering some of the busiest websites in the world, including Instagram, Pinterest, and Mozilla. For more examples of sites built with Django, you can visit BuiltWithDjango.com.
Conclusion
Choosing the right framework is crucial for successful web development, and Django stands out as a compelling choice. My journey with Django, despite its initial challenges, has been immensely rewarding. Django's extensive built-in features and strong security measures make it a robust framework for building sophisticated web applications.
Its track record of handling high-traffic sites like Instagram and Pinterest proves its scalability and reliability. Additionally, because Django is built on Python, it seamlessly integrates with other packages for data science, enhancing your ability to incorporate sophisticated data-driven functionalities into your applications.