Designing the application

When you have a fairly good idea of what you need to build, you can start thinking about the implementation in Django. Once again, it is tempting to start coding away. However, when you spend a few minutes thinking about the design, you can find plenty of different ways to solve a design problem.

You can also start designing tests first, as advocated in the Test-driven Development (TDD) methodology. We will see more of the TDD approach in Chapter 11: Testing and Debugging.

Whichever approach you take, it is best to stop and think:

  • What are the different ways in which I can implement this?
  • What are the trade-offs?
  • Which factors are more important in our context?
  • Finally, which approach is the best?

The best designs ...

Get Django Design Patterns and Best Practices - Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.