Oluwajuwon Faloreoluwajuwonfalore.hashnode.dev·May 23, 20245 Unpopular Hooks You Need to Know in REACTJSDo you want to optimize your code and take your development skills to the next level? Look no further! In this article, we'll explore five unpopular React hooks that you may not know about, but can greatly benefit from. Use Imperative Handle The firs...React
Maxi Contierimaximilianocontieri.com·Dec 24, 2023Code Smell 235 - Console Side EffectsTL;DR: Avoid side effects. Always. Problems Coupling Testability Reusability Function Composition Solutions Decouple the code and avoid side-effects Inject the output destination Context Outputting to the console within an internal functio...39 readsCode SmellsProgramming Tips
Maxi Contierimaximilianocontieri.com·Sep 3, 2023Code Smell 223 - Racial NamingTL;DR: Avoid old terms like whitelists, blacklists, master, etc. Problems Racial Connotations Exclusionary Language Diverse Perspectives Solutions Use alternative terminology Context Language evolves, and technical terms should follow it. You...2 likes·260 readsCode SmellsGeneral Programming
Mukesh Pareekmkshprk.hashnode.dev·Aug 30, 2023Design patterns that can help achieve the Single Responsibility Principle (SRP)We can achieve SRP by promoting the separation of concerns and ensuring that classes have a single responsibility. Here are some design patterns that can assist in adhering to SRP: Adapter Pattern: The Adapter pattern allows you to create a separate...design patterns
Christiaan Fouchéchrisfouche.com·Mar 30, 2023The Stable Dependencies PrincipleWhat if I told you change is coming? Lots of it. Like the domino effect, a simple code change could trigger a chain reaction that forces you to change many additional bits. A stable codebase is needed to minimise the propagation of this coming change...1 like·326 readscleancode
Maxi Contierimaximilianocontieri.com·Mar 26, 2023Code Smell 204 - Tests Depending on DatesTL;DR: Tests must be in full control and you can't manage time. Problems Fragile Tests CI/CD Breaks Solutions Tests should be always in full environmental control. Create a time source Context I read a Tweet about adding a fixed date to chec...10 likes·70 readsCode SmellsGeneral Programming
Jaap Groeneveldjgroeneveld.hashnode.dev·Oct 1, 2022About naming thingsThere is this one quote that I hear often repeated. There are only two hard things in Computer Science: cache invalidation and naming things. -- Phil Karlton But is it really true? Yes, finding the perfect name for something is difficult. But let u...80 readscleancode
Alexander Pushkarevtestingcoder.hashnode.dev·May 13, 2020Is Test-Driven Development effective?During some interesting discussion, one very respectful gentleman said “there are plenty of studies demonstrating the effectiveness of TDD”. But is it so? Test-driven development (TDD) has been a hot topic for a long time. There’re proponents and opp...55 readsTDD (Test-driven development)