Profiles and Groups in Django - Scaler Topics
How to Implement Multiple User Types with Django
Creating multiple user types and using proxy models in Python Django - GeeksforGeeks
Django Queryset of related objects, after prefiltering on original model
Overriding Django's RelatedManager methods
DRF and nested serialisers optimisation with prefect_related()
Speed up Django Nested Foreign Key Serializers w/ prefetch_related
Works beautifully, but the only problem? We’re making *tons* of DB calls like this. For every module we have, we’ll make one extra DB call with obj.lessons.all() , and for every lesson we have, we’ll make one extra DB call with obj.exercises.all() .
Utilizing docstrings
npm install jsdoc -g
Utilizing docstrings
When your file is correctly documented, just use the jsdoc CLI to create your documentation.
Integrate MDX with a single tool and less boilerplate. Manage content with type-safe data and helper functions. | delba.dev
The ability to use React.js components inside markdown is the main motivation for using MDX. You can use the useMDXComponent() hook to render the current posts "MDX enriched" markdown
Which Contentlayer (using a bundler under the hood) transformed into JSX and cached as static json
reddit
Building Better Next.js Static Sites With MDX and Contentlayer
Spotlight
artu-hnrq starred rehypejs/rehype on Github!
Next-Auth warning-issue
You set NEXTAUTH_SECRET in your .env.local like
Infisical | Open Source SecretOps
Use an environment file in Docker Compose
Single-quoted (') values are used literally
Compose supports parameter expansion in environment files.
Parameter expansion is applied for unquoted and double-quoted values.
Both braced (${VAR}) and unbraced ($VAR) expressions are supported.
Auto remove container with docker-compose.yml
What are "orthogonal" environment variables? [12-factor app]
Another aspect of config management is grouping. Sometimes apps batch config into named groups (often called “environments”) named after specific deploys, such as the development, test, and production environments
An illustrated guide to 12 Factor Apps | Enable Architect
The principle of Port Binding asserts that a service or application is identifiable to the network by port number, not a domain name. The reasoning is that domain names and associated IP addresses can be assigned on-the-fly by manual manipulation and automated service discovery mechanisms. Thus, using them as a point of reference is unreliable. However, exposing a service or application to the network according to port number is more reliable and easier to manage
12 factor app configuration vs leaking environment variables
they are are easy to change between deploys without changing any code
because the key and value both have to be plain text, it discourages
adding more complicated things as config settings when they really ought
not to need to be.
can be easily and reliably read using any of a variety of languages
(including shell scripts and the like) without complicated parsing code
or library dependencies
artu-hnrq starred dbrgn/drf-dynamic-fields on Github!
Dynamically extend serializer field list in Django REST fw
Advanced serializer usage — Dynamically modifying fields
The TSConfig Cheat Sheet
Saving objects and their related objects at the same time in Django
artu-hnrq starred beda-software/drf-writable-nested on Github!
Nested Serializers in Django Rest Framework
Intercept and replace serializer fields on initialization in Django
Nested annotate fields in Django REST Framework serializers