Talk Python To Me cover image

#277: 10 tips every Django developer should know

Talk Python To Me

Django Templates - Ten Ways to Write Templates That Work

2min Snip

00:00
Play full episode
Django has a construct that if there are no objects, then it goes into the empty block. So instead of like doing if books, look over the books and else there are no books, you can actually do four empty. It's just shorter, right? Oh my God. Is this a proper use for like an else block on a four, four in loop? Something like that. Yeah. Ten. Build and template tags and filters. And yeah, there's a bunch of stuff there. I think it's just good to assure writing a lot of templates where you're going to reference the objects that you pass in from the views.It's kind of handy to know how

Get the Snipd
podcast app

Unlock the knowledge in podcasts with the podcast player of the future.
App store bannerPlay store banner

AI-powered
podcast player

Listen to all your favourite podcasts with AI-powered features

Discover
highlights

Listen to the best highlights from the podcasts you love and dive into the full episode

Save any
moment

Hear something you like? Tap your headphones to save it with AI-generated key takeaways

Share
& Export

Send highlights to Twitter, WhatsApp or export them to Notion, Readwise & more

AI-powered
podcast player

Listen to all your favourite podcasts with AI-powered features

Discover
highlights

Listen to the best highlights from the podcasts you love and dive into the full episode