Automatically serve .webp or .avif with Node.js based on browser request headers.

Let’s chew down another issue: we have a /public folder with images, and depending on the browser we want to serve a WEBP or AVIF to save bandwidth and decrease page load time.

Automatically serve .webp or .avif with Node.js based on browser request headers. Read More »

Building a Preact application into a standalone script with Rollup

Rollup is a module bundler for JavaScript, made for speed and simplicity of setup. It also does tree-shaking (imports only the functionality you actually imported), supports JSX compilation and provides other neat functionality.

Building a Preact application into a standalone script with Rollup Read More »