Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

This is a situation where I enjoy coding in TypeScript. You don’t need to front with interfaces, you just mock objects that map 1:1 with the expected API. So you write your code targeting the standard Fetch API then just pass in a mock when testing.


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: