A bash alias for copying commands from the web
Learn how to eliminate the annoyance of copying dollar signs ($) along with terminal commands from the web with a simple bash alias.
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.
Learn how to eliminate the annoyance of copying dollar signs ($) along with terminal commands from the web with a simple bash alias.
Nesting elements with rounded borders can look very wrong if not done correctly. Here's a quick tip on how to do it right.
Effortlessly create upstream branches on push by enabling a simple git config setting.
Learn how to retrieve the first or last n
elements in a JavaScript array with a single line of code.
Messing up the order of chained then
and catch
methods in JavaScript promises can cause problems. Here's a short primer on the subject.
Ever needed to create a git commit with a different date? Here's a quick and easy way to do it.
Configure user information for Git to associate commits with a user.
Learn how to fetch the latest changes from the remote repository in Git and keep your local repository up to date.
Learn how to apply changes introduced by one or more commits to your current branch (cherry-picking).
Resource prefetching is a great way to improve perceived page speed on your website and requires little effort. Learn how to use it today.
Figure out the exact number of bytes in a JavaScript string, including Unicode characters.
Numeric separators are a somewhat lesser-known JavaScript syntactic sugar that can make working with large constants a lot easier.
It's generally not a good idea to use bare except
clause in Python, but do you know why?
Learn how to configure the text editor used by Git for commit messages and other text editing tasks.
Learn how to view the current status of the working tree in Git.
Ever needed to convert a decimal number to hexadecimal? Here's a quick and easy way to do it.
Learn how to create a generator function that keeps producing new values as long as the given condition is met.
Learn the difference between two common ways to access values in Python dictionaries and level up your code today.
Multiple useState
hooks in React can complicate things while debugging. Luckily, there's an easy way to label these values.
Have you accidentally deleted a file? Or maybe you need to restore a file that was deleted? Here's how Git can help you.
Number-only inputs aren't as straightforward as you might expect. Here's a user-friendly way to set them up.
Opening a link in a new tab comes with a security vulnerability that you may not be aware of. Protect your users with this simple trick.
Easily and reliably calculate the width of the browser's vertical scrollbar with JavaScript.
A quick, one-liner to generate a random boolean value in JavaScript.