HNHacker News
TopNewBestAskShowJobs

WebReflection

14 karma · joined January 17, 2012

submissionscomments
WebReflection··on Firefox extension to redirect x.com to xcancel.com
I used to have an extension per each domain then I've decided to publish regurlator https://chromewebstore.google.com/detail/regurlator/jfgfmidm... ... this case would be like `^https:\/\/(?:x|twitter)\.com\/(.+)?$` `https://xcancel.com/$1` so you have a single extension with as many rules as you like and you can download/share/restore rules with ease (it's just a JSON file).
WebReflection··on TS to JSDoc Conversion
JSDoc TS is well documented: https://www.typescriptlang.org/docs/handbook/jsdoc-supported...

It's not 1:1 in features though, but because you can import definitions https://www.typescriptlang.org/docs/handbook/jsdoc-supported... you can use a file a part whenever you encounter any of those advanced features / edge cases current JSDoc does not support.

Like other said, it's still TS after all, and there are escape hatches when needed.

In so many projects I use JSDoc TS, the amount of projects that ended up needing a manual .d.ts file not utomatically generated via `tsc` can be counted in half hand.

Maybe people could give it a try, after all if you comment a method, beside its signature and return types, you can as well just move types in there ;-)

WebReflection··on Destructuring and Recursion in ES6
or does it? You are passing arrays of arrays with a potentially random index position based convention that makes no sense to me at first read.

Is that how you pass on real-world code a generic person data around?

Is that how you don't use i18n for string and how you ignore occupations that starts with vowels?

Destructuring is nice as other new features in ES6 but abusing these just because there are there ... no, I don't think that's going to improve any code or any readability.