Getting started with Django 4
Getting started with Django 4
Your roadmap to developing web applications in Python with Django begins here
About the Book
Django is a framework with many options, it allows us to create applications with the language of the moment Python, a modular programming language, with an impeccable syntax that we can also use in a web environment.
It offers us a modular scheme between projects and applications, an important set of packages to extend the already complete framework and with this, the creation of scalable projects.
It is a framework that, by using Python, brings us its benefits of a clean, clear, precise syntax, a modular and scalable environment through packages.
This book is for anyone who wants to start developing with Django; you may come from another framework or even PHP; in both cases, it is a great idea to learn from one of the most advanced and complete web frameworks you can find.
For those who want to know the framework and who know other web frameworks, but do not have the necessary knowledge to venture into these.
For people who want to improve a skill in web development, who want to grow as a developer and who want to keep climbing their way with other frameworks similar to this one.
For those who want to learn or improve a skill and with this, increase their chances of employment or to carry out a personal project.
- Chapter 1: In this chapter we are going to present the necessary software to create projects in Django, what happens from Python, to preparing the environment.
- Chapter 2: In this chapter we are going to install Python, create a project and applications and get to know the folder structure of the framework.
- Chapter 3: In this chapter, we are going to create a simple CRUD application and learn about all the elements of the framework that this implies, such as handling forms, templates, views and models.
- Chapter 4: In this chapter, we're going to work with Django Admin to provide an interface for managing site content; that is, the typical CRUDs.
- Chapter 5: In this chapter, we are going to introduce the use of forms in Django, definition, validations, saving and structure in general.
- Chapter 6: In this chapter, we are going to present the different functionalities that templates have in Django.
- Chapter 7: In this chapter, we are going to introduce some functions that we can use with QuerySets when building queries.
- Chapter 8: In this chapter, we are going to build a Rest API with the Django Rest Framework.
- Chapter 9: In this chapter, we are going to consume the above Rest Api with an app in Vue 3 and NaiveUI; lists, forms will be created and integrated with Tailwind.css
- Chapter 10: In this chapter, we are going to learn about class-based views by performing the typical operations that are needed in modern web development.
- Chapter 11: In this chapter, we are going to learn how to work with files in Django; specifically reading and generating excel and CSV and generating PDFs.
- Chapter 12: In this chapter, we are going to show the code of an application created with Alpine.js to create a to do list component.
- Chapter 13: In this chapter, we are going to adapt the Alpine.js application introduced in the previous chapter, to work in conjunction with Django.
By the end of the book, you will have the knowledge to create any basic application with the framework and know more than just the basics of it.
I invite you to visit my website:
And get to know my work.
- Getting started with Django 4
- Tweet about the book!
- About the Author
Chapter 1: Required software and installation of tools
- Required Software
Chapter 2: Getting started with Django
- Packages and best practices when working with Python
- Prepare the development environment
Chapter 3: Create a CRUD application
- Introduction to migrations
- Run the project on a server
- Views, templates and routes
- Views, templates, routes and forms
- Save the data in the database
- Create a CRUD process
Chapter 4: Django Admin
- Add our own relations
- Customize Django Admin
- Register classes using a decorator
Chapter 5: Forms
- Django ModelForm
- Django Forms
- Case study
- Reference the fields and labels of the form individually
Chapter 6: Templates: Master Templates, Labels, and Filters
- Render dynamic content
- Chapter 7: Working with QuerySets
Chapter 8: Create a Rest API with Django Rest Framework
- Create a Rest API in Django
- Create application for the Rest API
- Django Rest Framework in practice
Chapter 9: Consuming the Rest API with an app in Vue
- Prepare the environment
- Vue Router
- Configure axis
- Naive UI, for graphical interface components
- Install and configure Tailwind CSS
- Fix small details
- Bonus: Introduction to overriding the NaiveUI theme
- Form component for the type
- Form component for the element
- CKEditor: Editor for rich content
- Navigable menu options
- Format of the dates in the rest api
- Redirects on nonexistent routes
- Visual changes
- Multiple router-views
Chapter 10: Class Based Views (CBV)
- Create a project and application
- Create model, migration and form
- Class-Based Views
- CRUD-like class-based views
- Class-based views for authentication
Chapter 11: Reading Files
- Create a project and application
- CSV handling
- Excel handling (XLSX)
- Generate PDF
- Chapter 12 : Create an Alpine.js to do list application
Chapter 13 : Integrating Alpine with Django
- Create virtual space, project and initial application
- Migrate to do list app to Django
- Create model and migration for the to do
- Create a Rest API for the to do
- Install axios
The Leanpub 60-day 100% Happiness Guarantee
Within 60 days of purchase you can get a 100% refund on any Leanpub purchase, in two clicks.
See full terms
80% Royalties. Earn $16 on a $20 book.
We pay 80% royalties. That's not a typo: you earn $16 on a $20 sale. If we sell 5000 non-refunded copies of your book or course for $20, you'll earn $80,000.
(Yes, some authors have already earned much more than that on Leanpub.)
In fact, authors have earnedover $12 millionwriting, publishing and selling on Leanpub.
Learn more about writing on Leanpub
Free Updates. DRM Free.
If you buy a Leanpub book, you get free updates for as long as the author updates the book! Many authors use Leanpub to publish their books in-progress, while they are writing them. All readers get free updates, regardless of when they bought the book or how much they paid (including free).
Most Leanpub books are available in PDF (for computers) and EPUB (for phones, tablets and Kindle). The formats that a book includes are shown at the top right corner of this page.
Finally, Leanpub books don't have any DRM copy-protection nonsense, so you can easily read them on any supported device.