Hacker News new | ask | show | jobs
by ficklepickle 768 days ago
TypeScript is nice here because you can specify the specific strings you accept in a union. Eg. `unit: 'AC'|'DC'`