Archive
- Adding an SVG favicon with dark mode support• 4 min
Updating my favicon and adding support for dark mode.
- Optimising CSS minification in Liquid• 5 min
Optimising a technique to use Liquid to minify CSS code for performance in Shopify themes.
- Avoiding a DOMContentLoaded gotcha with readyState• 2 min
I recently hit a race condition when a script was loading faster in some browsers.
- Prefill a Shopify discount with the Fetch API• 2 min
Set a prefilled discount in checkout with a fetch request.
- Implement a low stock notice in a Shopify theme• 5 min
A simple way to display a notice when the selected variant has a stock quantity below a specified value.
- Quick error reporting with Val Town• 6 min
Using Val Town's simple storage and notifications to rig up a lightweight error reporting system.