A Netlify Serverless Function in one Tweet

Your first serverless function in one tweet: 1. Save this as `functions/my-first-function.js`: exports.handler = async () => ({ statusCode: 200, body: 'boop',}); 2. Deploy to Netlify3. Call it at <your site>/.netlify/functions/my-first-functionhttps://t.co/cRgT9Yxbmy — Netlify (@Netlify) December 20, 2019 This is cgi-bin all over again, right? 💡 Looking to deploy a website to Netlify? You can find …

Native Image Lazy Loading in Chrome Is Way Too Eager

UPDATE 2020.07: the thresholds have been adjusted to be less eager: We’ve improved <img> lazy-loading in Chrome! https://t.co/zx8sf7I86L The new thresholds for when we load <img loading=lazy>: * Offer *much* better data-savings* Are closer to JavaScript lazy-loading libraries* Are rolling out to Chrome 79+ pic.twitter.com/3OHm2rnRAm — Addy Osmani (@addyosmani) July 17, 2020 For the Web …

A/B Street – A traffic simulator written in Rust

Ever been on a bus stuck in traffic, wondering why there are cars parked on the road instead of a bus lane? A/B Street is a game exploring how small changes to a city affect the movement of drivers, cyclists, transit users, and pedestrians. I should send this to my local government, as they keep …

Drawing Tip: A thicker pen hides mediocrity

Your drawings probably look rubbish because you’re using an old biro that happened to be laying around. Nobody’s used one of these since cassette tapes stopped needing to be fixed, so throw that in the drawer full of batteries, twine and assorted electrical tape from whence it came. Instead, go thicker. Go felt tip. Go …

Simon Sinek: Performance vs. Trust

The problem in business is we have lopsided metrics. We have a million-and-one metrics to measure someone’s performance, and negligible to no metrics to measure someone’s trustworthiness. 👉 You might know Simon from other videos such as Millennials (in the Workplace) or Why Leaders Eat Last. Totally worth your time.

Avoid Guzzle 6.5.0 (aka How to fix “Use of undefined constant INTL_IDNA_VARIANT_UTS46” on CentOS 6)

There’s a bug in Guzzle 6.5.0 in which it does not play nice with systems that have an older ICU library (which PHP’s Intl extension uses). CentOS 6 for example ships with a very old ICU version, without any (offical) means of updating it. The bug should be fixed in (the unreleased) Guzzle 6.5.1. It …

How the CSS :is() selector will simplify things

One of the selectors in CSS Level 4 is :is(). It is the successor to :any() and :matches() (which are supplanted by :is()): The :is() CSS pseudo-class function takes a selector list as its argument, and selects any element that can be selected by one of the selectors in that list. This is useful for …

Why <details> is Not an Accordion

Dave Rupert on why that (wonderful) way of Using the <details> element to create modals and menus is not good for semantics. Because <summary> has role=”button”, it eats the semantic content of elements inside it. So that big <h1> inside of your <summary> becomes just another piece of text, sans semantics. I especially like this …