|
|
|
|
|
by semicolon_storm
1412 days ago
|
|
Is this what modern idiomatic TS looks like? Reading through the pipe implementation, as someone who primary works in the relatively "boring" world of backend languages, this looks like the kind of code that would get shot down review for being too clever and not very readable, regardless of how "elegant" it may be. Using triple assignments (a = b = somevalue)? Using λ as a type name instead of writing out lambda with symbols that are actually easy to type? Overloading/reusing variables that makes it hard to mentally trace how data flows through? |
|
When I started this project it was just for my own personal use and kind of a creative / intellectual outlet for me where I didn't have to make any compromises and adhere to anyone else's style. So to this day some of the code might be a bit... exotic. It's definitely not how I'd write it in my day job.
That's the JS part. The type-definitions I'm afraid are just unreadable because it's TypeScript. I feel they're like regexes in that regard: write once and try not to touch them again.