Extreme explorations of TypeScript's type system
You can do some truly silly things with sufficiently ridiculous uses of typescript.  I built a typecheck-time spell checker[0] in it such that:<p><pre><code>  import { ValidWords } from "./spellcheck";
  
  // Typechecks cleanly:
  const result: ValidWords<"the quick brown fox."> = "valid";
  
  // Throws a type error
  const result: ValidWords<"the qxick brown fox."> = "valid";

</code></pre>
[0] <a href="https://github.com/kkuchta/TSpell" rel="nofollow">https://github.com/kkuchta/TSpell</a>