Generate Django Secret Key

Aug. 10, 2023 | Tags: django TIL

Every now and again, I need to generate a Django secret key. And I always forget what is the function I have to call, and I end up looking it up every time.

[Read more]

Django REST Envelope

April 9, 2023 | Tags: django django-rest-framework

In the list endpoints of a REST API, you usually send a list of objects. However, in the Django REST framework and, in particular, when using viewsets, the list method does return a list. But oftentimes it's very useful to return an object that has a key that contains that list. Why? Because you can send additional data, such as pagination, for example, without having to make breaking changes, among other things.

[Read more]

Django Simple Analytics

Aug. 29, 2022 | Tags: python django open source

Few months ago, on this very website, I implemented a very simple analytics tool to check how many people went into my website. A few days ago, I decided to move this out of my website and into its own separate package.

[Read more]

First ever blog post!

Aug. 21, 2021 | Tags: python django sqlite

For a while I have been wanting to have a blog to be able to share things I learn during my webdev journey. Creating a website and deploying it was one of the first steps in that direction back in 2019, before I joined Red Points. It was a very simple (well, still is) flask website with jinja2 templates and some data passed for the urls and so on. After I learned Django at Shalion, I decided to move from Flask to Django to have more capabilities moving forward and since I really like Django it was a perfect way to be able to have a small project to test packages and so on.

[Read more]