David BarralinTrabeWhen to Type your Return Types in TypeScriptAlmost always the answer is never. Just let TS do its thing and use/test your APIs.Feb 22, 20233Feb 22, 20233
David BarralinTrabeThe Many Levels of Dependency InjectionThe moral of this story is not about software design at all.Jun 20, 20221Jun 20, 20221
David BarralinTrabeDebugging Node.js with pp (pretty-print)Rubyist often use the handy global pp method to do quick console debugging. It’s easy to do the same in Node.jsJun 10, 2021Jun 10, 2021
David BarralinTrabeControl What you Publish Inside your Npm PackagesThe own your mistakes editionMay 5, 20211May 5, 20211
David BarralinTrabeBe Mindful of Your CommentsThis could have been a story about how and when to use comments in code, but it’s not. It’s about being a respectable human being.Dec 21, 2020Dec 21, 2020
David BarralinTrabeWhy We Keep Teaching React Class ComponentsWe’ve been teaching React for several years now. Since the introduction of Hooks we’ve adapted our courses, but what about class components?Dec 14, 20205Dec 14, 20205
David BarralinTrabeFetch API Errors and the Principle of Least SurpriseThe Fetch API does not follow the principle of least surprise when dealing with errors, so it causes problems to inexperienced developers.Dec 7, 2020Dec 7, 2020
David BarralinTrabeUsing Function Composition Instead of Options to Build Flexible APIsFunctions and composition can help us build flexible APIs that are easy to understand, maintain and extend.Nov 2, 20205Nov 2, 20205
David BarralinTrabeAsync Getters and Setters. Is it Possible?Not having an async get/set syntax is a shame, but we can overcome this limitation with simple workarounds.Oct 26, 20209Oct 26, 20209
David BarralinTrabeFlexible Authorization Component in React Using FunctionsThe way to configure how something behaves in JS is using functions. With functions and composition we can create flexible an reusable APIsOct 19, 20201Oct 19, 20201