Javascript

Programatically change class on Vue.js elements

Do you want to change a class of some element programatically using Vue.js? That is actually a simple task to complete. Let’s imagine that you want to toggle between dark-mode and light-mode classes. Just use something like class=“[ lightMo...

Copy text to clipboard with Javascript

One thing that I find myself searching for from time to time, is how to copy a specific text on my app to the clipboard, when the user just clicks on a button or some action occured. My most recent example, was to copy the current IP of the...

How to Make First Letter Uppercase in Javascript

If you have the need to uppercase just the first letter of a string in JavaScript like I did, just keep reading this article, because this is for you. There are multiple ways to achieve this, so I’ll try to document them the best way ...