Converting days to years, months and days | JavaScript
A simple function for converting days to years, months and days.
Read articleExplore. Learn. Build.
JavaScript is what makes a website interactive. You can do so many cool things with vanilla JavaScript.
Find your next idea.
From the archive
Showing 1–12 of 18
A simple function for converting days to years, months and days.
Read articleCommenting your code is important for readability and maintainability. Here's a couple of ways to add comments to your JavaScript code.
Read articleSometimes you want to run a function a few seconds after the user has opened your website or similar. In this short guide, I'll show you how to do this.
Read articleThere are a lot of different things you can do with JavaScript arrays. In this little guide, I'll go through some of them.
Read articleSorting an array alphabetically or numerically is something we often do as programmers, but how do you do this using JavaScript?
Read articleReplacing strings in JavaScript can be done in many different ways. In this guide, I'll show you a couple of them.
Read articleIn this little guide I'll show you how you can use JavaScript to check if a string starts with a certain word.
Read articleSplitting a string using JavaScript is something you do from time to time. But it's easy to forget the syntax, here's how you can split a string.
Read articleLet me show you how to use JavaScript to programmatically disable or enable a button.
Read articleA random string can be used for a lot of different purposes like password, filename, etc. But how do you generate one?
Read articleGenerating random number using JavaScript isn't hard, but you need to know how to do it.
Read articleSometimes you need to optimize your website by either using throttle or debounce, but what's the difference?
Read articleKeep exploring
Put what you've learned to work in a complete project.