How can you take advantage of the Django framework to integrate complex client-side interactions and real-time features into your web applications? Through a series of rapid application development projects, this hands-on book shows experienced Django developers how to include REST APIs, WebSockets, and client-side MVC frameworks such as Backbone.js into new or existing projects.
Learn a lightweight approach for starting a new Django project
Break reusable applications into smaller services that communicate with one another
Create a static, rapid prototyping site as a scaffold for websites and applications
Build a REST API with django-rest-framework
Learn how to use Django with the Backbone.js MVC framework
Create a single-page web application on top of your REST API
Integrate real-time features with WebSockets and the Tornado networking library
Use the book’s code-driven examples in your own projects
Julia Elman is a designer, developer, and tech education advocate based in North Carolina. She has been working on her brand of web skills since 2002. Her creative nature drove her to find work in 2007 at Hallmark Cards, Inc., where she worked on projects such as the Product (RED) campaign and Hallmark’s site redesign. From there, she took a dive into Django as a junior designer/developer at World Online in Lawrence, Kansas. In early 2013, she helped start a local chapter of Girl Develop It and empowered over 600 members to learn computer programming. She also helped organize the 2013 Teen Tech Camp, where 20 local teens learned Python programming in a one-day event.
Mark Lavin is a lead Python/Django developer at Caktus Consulting Group in Carrboro, North Carolina. He also runs a small homebrewing website, written in Django, called brewedbyus.com. He came to Python web development after a few years pricing derivatives on Wall Street. Mark maintains anumber of open source projects primarily related to Django development and frequently contributes back to projects used by Caktus. When he isn’t programming, Mark enjoys spending time with his wife and daughter, brewing beer, and running.
The animals on the cover of Lightweight Django are vervain hummingbirds (Mellisuga minima). Native to Jamaica, Haiti, and the Dominican Republic, these non-migratory hummingbirds are common, favoring subtropical and tropical lowland forests.While lacking the bright, jewellike plumage of other hummingbird species, they are notable for being the second smallest bird in the world, after the bee hummingbird of Cuba. The vervain measures roughly 2.4 inches in length, including its bill, and weighs between .07 and .08 ounces. These birds primarily feed on nectar from flowers, using their extendible tongues to lap up the nectar at a rate of 13 times per second.Hummingbirds are solitary creatures, coming together only to breed. The male disperses immediately after copulation, leaving the female to build the nest and raise the young. These eggs are the smallest laid by any bird, at just a third of an inch in length, weighing .375 grams on average. Nests are barely the size of half a walnut shell.Despite its diminutiveness, the vervain produces a loud, piercing song—often the only indication of its presence, as this bird can be difficult to spot due to its size. Highly vocal, the birds turn their heads from side to side as they sing.
I bought this book at the suggestion of a fellow PythonKC member, and I must say I'm very impressed. By "deconstructing" a Django application to the absolute minimum requirements and building back up from that base, the authors have shown me that many things I thought I knew about Django weren't true, and I'm glad to have been wrong.
The only negative I can give is that it isn't finished!
Bottom Line Yes, I would recommend this to a friend
Begins with a refreshing and insightful introduction to Django. Follows with code quality and practices which range from average to mostly awful. In chapter 3 alone, don't write content back into the code base, don't lump everything into views, don't import django.test.client into the implementation. This is very unfortunate because the ideas and goals of the book are very good, just poorly executed.
Bottom Line No, I would not recommend this to a friend
If you are a python hacker and you are embracing the web via APIs and microservices (and you should be), this book is your new best friend. This book should have a wide appeal-- from students and novices who want to start simply, to experts who want to restore sanity to complex systems.
It starts by showing how pythonic django is by building the smallest functional web service possible. It does a nice job of showing that django compares well to bottle.py and flask for simplicity. Django's strength lays in it's ability to scale to complex requirements, without outgrowing its applicability. Latter in the book, the marvelous django-rest-framework is used to build restful APIs with authentication and optional admin tools.
I'm greatly enjoying the book so far, and looking forward to the rest of the material as it's added.
Bottom Line Yes, I would recommend this to a friend