16 Matching Annotations
  1. Oct 2022
    1. I'm afraid you missed the joke ;-) While you believe spaces are required on both sides of an em dash, there is no consensus on this point. For example, most (but not all) American authorities say /no/ spaces should be used. That's the joke. In writing a line about "only one way to do it", I used a device (em dash) for which at least two ways to do it (with spaces, without spaces) are commonly used, neither of which is obvious -- and deliberately picked a third way just to rub it in. This will never change ;-)
  2. Oct 2021
  3. Jul 2021
    1. This is one of the more-satisfying ruby expressions I've seen in a long time. I can't say that it also has prosaic transparency, but I think seeing it teaches important things.
    2. x = -3 "++-"[x <=> 0] # => "-" x = 0 "++-"[x <=> 0] # => "+" x = 3 "++-"[x <=> 0] # => "+"
  4. Apr 2021
    1. Explicit affordances are obvious, perceptual features of an item that clue you in on how it is to be used. With explicit affordances, physical appearance and any accompanying language or text inform the user of how an object is to be used.
  5. Mar 2021
  6. Oct 2020
    1. You might think something like “don’t request the same resource thousands of times a day, especially when it explicitly tells you it should be considered fresh for 90 days” would be obvious, but unfortunately it seems not.
  7. Sep 2020
    1. This is so common that ECMAScript 2020 recently added a new syntax to support this pattern!export * as utilities from "./utilities.js";This is a nice quality-of-life improvement to JavaScript, and TypeScript 3.8 implements this syntax. When your module target is earlier than es2020, TypeScript will output something along the lines of the first code snippet.
  8. May 2020
    1. If you update your pages and push to github, people revisiting the pages who have already got cached copies will not get the new pages without actually cleaning their browser cache. How can a script running in a page determine that it is stale and force an update?
  9. Mar 2017
  10. Sep 2013
    1. But men who inculcate virtue and sobriety--is it not absurd if they do not trust in their own students before all others?

      It's almost as if they saw this as a job.