Today I Learned
Scroll To Text Fragment
March 12, 2025TIL that you can link to a specific text on a webpage by appending #:~:text=
to the url, .e.g. https://en.wikipedia.org/wiki/Tree#:~:text=Trees evolved around 370 million years ago. It’s called Text Fragment.
Python Dependency Checker
February 27, 2025I discovered Tach, a static code checker for Python projects to enforce dependencies between modules. For example in a layered backend architecture you can enforce that controller
modules can only depend on service
and repository
modules and, e.g. repository
modules cannot import from controller
modules. Looks interesting also to enforce code boundaries between modules (or components) in a modular monolith. I’d like to check it out in one of my next projects.
Vite Proxy Server
February 25, 2025Today I learned that Vite has a proxy server config so that in local development API requests can go to http://localhost:3000/api
while the server can run on http://localhost:5000
. This saves you from having to configure CORS in the backend for local dev purposes only.
JSDOM
February 24, 2025Blog post by Artem Zakharchenko (creator of MSW) about JSDOM, the issues with re-implementing a browser env in Node, and alternatives like Vitest Browser Mode.
Figma/Tailwind Semantic Design Tokens Tutorial
February 24, 2025Epicweb.dev has a great, free tutorial on how to use semantic tokens with Tailwind and Figma.