Finding ways to improve and optimize your code takes a lot of time, research and energy. Level up your coding skills one step at a time with this collection of quick tips and tricks.
Here's a quick tip on how to compare and sort arrays of strings, ignoring case and accents.
JavaScript, String · Jul 17, 2022
Dynamically adding object properties can be pretty slow in some cases. Here's how to optimize it.
JavaScript, Object · Nov 2, 2022
There are many ways to create empty links, some more appropriate than others. Learn how to best handle empty links with this quick tip.
JavaScript, Browser · Jun 12, 2021
The currentColor
CSS keyword is a nifty alternative to custom properties for simple use cases.
CSS, Visual · Nov 30, 2022
Make sure to use the correct method when checking if a JavaScript object is an array.
JavaScript, Type · Nov 6, 2022
Mutable default arguments can trip up Python beginners and veterans alike. Here's a quick workaround to deal with them.
Python, Function · Feb 27, 2022
Avoid unnecessary re-runs by using primitive dependencies in your React effect.
React, Hooks · Jun 12, 2022
Scroll listeners can easily become a performance bottleneck for your web application. Here's how to fix that.
JavaScript, Browser · Mar 7, 2023
Learn how to sort a Python dictionary list using a tuple key.
Python, List · Jan 4, 2023
Iteration in JavaScript can be done a handfuld of ways, most often using array methods, but sometimes a for
loop is the best option.
JavaScript, Array · Jun 12, 2021
Increase your JavaScript code's performance when working with the DOM by leveraging this simple trick.
JavaScript, Browser · Jun 12, 2021
Have you ever tried to convert the string representation of a boolean to an actual boolean value? Here's a simple way to do it.
JavaScript, String · Sep 14, 2022
Learn how to use the cubic-bezier()
class of easing functions and create beautiful animations that stand out.
CSS, Animation · Jun 12, 2021
A short summary of your story up to 180 characters long.
CSS, Visual · Nov 23, 2022
Strings in JavaScript can be escaped in various ways. But how do you prevent a string from being escaped? Here's a handy trick for that.
JavaScript, String · Jun 17, 2021