django-planet

Blog: Matt Layman

web https://www.mattlayman.com/tags/django/
Author

How To Use Htmx In Django

Feb. 6, 2021 » Django on Matt Layman » [Archived Version]

This article shows you how to use htmx in Django. What is htmx? According to the htmx website: htmx allows you to access AJAX, CSS Transitions, WebSockets and Server Sent Events directly in HTML, using attributes, so you can build modern user interfaces with the simplicity and power of hypertext. The example that we’ll craft is an ability to delete a task from a list of tasks without reloading the whole page.

Read More

UX Polish - Building SaaS #90

Feb. 4, 2021 » Django on Matt Layman » [Archived Version]

In this episode, I worked on more customer requests to refine the user interface. We added a new convenient shortcut button and included additional information and links on the course detail view. I’m continuing on my path to include the changes that my customer wants as she running a school year for the first time. The first change was to add a new button on the student’s view of a course.

Read More

Are Django and Flask Similar?

Jan. 30, 2021 » Django on Matt Layman » [Archived Version]

Maybe you’re new to web development in Python, and you’ve encountered the two most popular Python web frameworks, Django and Flask, and have questions about which one you should use. Are Django and Flask similar tools for building web applications? Yes, Django and Flask share many similarities and can both make great websites, but they have some different development philosophies which will attract different types of developers. What do I know about this?

Read More

Customer Feature - Building SaaS #89

Jan. 28, 2021 » Django on Matt Layman » [Archived Version]

In this episode, I show you how to take a feature idea from nothing to something. We added new UI, wrote a new view, a new form, and all the associated test code to prove that the feature works. My customer wants the ability to complete a task on any day she desires. The feature flow looks like: Click a calendar icon next to a task on a student’s course page.

Read More

Which Django Version Should I Use?

Jan. 23, 2021 » Django on Matt Layman » [Archived Version]

Django is a big and popular web framework for Python to help you build a web app. Which Django version should you use? If you’re starting a Django web app, use the latest version of Django available. Why listen to me? I’m a software developer with over 7 years of professional Django experience. I work at companies that use Django successfully at the core of their business. I’ll explain why you should use the latest.

Read More

Customer Requests - Building SaaS #88

Jan. 21, 2021 » Django on Matt Layman » [Archived Version]

In this episode, I worked on some customer requests now that I’ve finished launching the product. These requests improved the usability of the application in a few spots that were lacking. The first request from the customer was to make it clear on the daily view when tasks are graded or not. Before I could change the template, I need to add a new method to the CourseTask to check if the task is graded.

Read More

Squashing Bugs - Building SaaS #87

Jan. 14, 2021 » Django on Matt Layman » [Archived Version]

In this episode, I fixed some critical issues that my customer discovered. My customer is putting the app through its real paces for a school year and since this is the first run, there were bound to be some bugs. We began with an explanation of the issues that my customer encountered. The problems related to scheduling. First, the daily page skipped a task and showed the task that was meant for two days in the future.

Read More

Episode 11 - Here, There, Middleware

Jan. 11, 2021 » Django on Matt Layman » [Archived Version]

On this episode, we will investigate Django middleware and see where it goes in your project. In the process, you’ll see why middleware is useful and how you can work with it. Listen at djangoriffs.com. Last Episode On the last episode, we’re going to look at working with users in a Django project. We’ll see Django’s tools for identifying users and checking what those users are permitted to do on your website.

Read More

Testing Email Designs - Building SaaS #86

Jan. 7, 2021 » Django on Matt Layman » [Archived Version]

In this episode, I worked on the sign up confirmation email design. We customized the template and used MailHog to test the flow and see how the email appeared. After working on the email design, we switched to the landing page of the site to work on the pricing information. I started the stream by explaining that I’m working through some final tasks before launching the app more publicly. I covered why I am planning to send a sign up email and why I want to customize it.

Read More

Serving Static Files

Jan. 6, 2021 » Django on Matt Layman » [Archived Version]

In the previous Understand Django article, I described how Django gives us tools to run code for any request using the middleware system. Our next focus will be on static files. Static files are vital to your application, but they have little to do with Python code. We’ll see what they are and what they do. From Browser To DjangoURLs Lead The WayViews On ViewsTemplates For User InterfacesUser Interaction With FormsStore Data With ModelsAdminister All The ThingsAnatomy Of An ApplicationUse…

Read More