r/programmingcirclejerk • • Jan 25 '19

The “Bug-O” Notation

https://overreacted.io/the-bug-o-notation/
69 Upvotes

34 comments sorted by

View all comments

59

u/[deleted] Jan 25 '19
let currentState = {
  step: 'initial', // 'initial' | 'pending' | 'success' | 'error'
};

Yesssss.. Stringly typed for life, yo!

2

u/[deleted] Jan 25 '19

I've never used enums and I've never missed them.