alecode.hashnode.devTypecript: Overloading functions with tuplesOverloading a function on a programming language means using the same function but with different types of arguments or increasing the number of arguments. What are tuples? Is a mechanism in typescript to strictly define an Array, define size, define...Apr 24, 2022路3 min read
alecode.hashnode.devAvoiding unexpected calls from useEffect on re-renders with useCallback and useRef approachesThe practice of put in place useCallback https://reactjs.org/docs/hooks-reference.html#usecallback is useful because guarantees that a function won't change unless its dependencies change, and making sure we can pass down that function to any other ...Sep 19, 2021路3 min read
alecode.hashnode.devNextJS Intl: Mixed-up markup translationsToday will talk about how to handle complex translations with HTML elements in the middle with NextJS Intl . Prerequisites Would assume you have heard already about NextJS Intl or a similar library. If not, take a look at the link added previously. ...Aug 17, 2021路1 min read
alecode.hashnode.devIllustrating: The power behind JS Array.reducerArray API during the latest years is becoming more and more powerful, there are a lot of useful functions that we can rely on every day, but one that has many use cases when transforming arrays into other types: objects, strings, numbers and you cont...Aug 2, 2021路2 min read
alecode.hashnode.devUse Cases: Lazy Loading with React SuspenseLazy loading is an approach to load incrementally parts 馃殌 of your app, these could be a route component that is not used often or even a component that depends on heavy dependencies, we'll focus on these 2 use cases. FYI: there is part of this API...Jul 22, 2021路2 min read