Re:Design Doc: Use JavaScript instead of TypeScript for inte...
by mikewhy on Monday June 08, 2020 @11:23PM
(#23463348)
This also works in TypeScript's favor. Meaning you can skip writing tests that simply check you're giving the correct props.
[ Parent
| on HN ]
Re:Design Doc: Use JavaScript instead of TypeScript for inte...
by nailer on Tuesday June 09, 2020 @12:20AM
(#23463604)
I don't think anyone /does/ write tests that simply check they're giving the correct props. They write unit tests, and props are part of that.
Re:Design Doc: Use JavaScript instead of TypeScript for inte...
by eyelidlessness on Tuesday June 09, 2020 @12:45AM
(#23463731)
This also works in TypeScript's favor. You get test coverage which you would never write. A "simple" component that doesn't have any logic and doesn't warrant a test still checks its prop types, and you don't have to do anything other than make the compiler pass.