Categories
Posts

A minimal reverse proxy using PHP & cURL

A reverse proxy acts as an intermediary between a client and one or more servers. Requests sent by the client are received by the proxy and passed on to one of the servers in the background. There are many scenarios in which such a setup might be useful. For example, reverse proxies can be used […]

Categories
Posts

Whitelisting files in Serverless

By default, the Serverless framework will deploy every file in the project directory. In most cases, this is not what you want. serverless.yml offers the option to control which files will be deployed to your cloud provider by using the exclude / include parameters. Due to the way these parameters are implemented, it is not […]

Categories
Posts

Busting some caches with Django

In contrast to server-side code, client-side assets such as JavaScript files and static images are not directly deployed to where they are ultimately executed or displayed (i.e. the user’s browser). Rather, they are downloaded on demand whenever a browser retrieves a page for the first time. For sake of efficiency, the browser saves the retrieved […]

Categories
Posts

Prevent Gutenberg from breaking words in table blocks

For some reason, the Gutenberg editor applies the following CSS rule to table block cells: This rule will make your tables look something like this: As you can see, a cell’s text content will be wrapped mid-word which might not be the behavior you’d expect from your table cells (at least it wasn’t was I […]

Categories
Posts

He or She? Or: The basics of (binary) classifier evaluation

Of all the amazing scientific discoveries of the 20th century, the most astonishing has to be that “men are from Mars, [and] women are from Venus”. (Not that the differences weren’t obvious pre-20th century, but it’s always good to have something in writing.) If indeed the genders do originate from different planets, then surely the […]