Short Pieces
How to Sort by Date in JavaScript?
16 April 2025
Learn how to sort by date in JavaScript with simple examples. Sort arrays of date strings or objects with date fields using JavaScript’s sort() method.
Group by Year, Month, or Day in MySql
13 April 2025
How to group data by specific date interval using DATE_FORMAT(), EXTRACT() functions, and some helpers like YEAR(), MONTH(), DAY(), and DATE() in MySQL.
Group by Year, Month, or Day in PostgreSQL
26 June 2023
How to group data by specific date interval using DATE_TRUNC(), EXTRACT(), or TO_CHAR() functions in PostgreSQL.
Exponentiation in JavaScript: A Beginner's Guide
22 June 2023
Exponentiation refers to a mathematical process of multiplying a number by itself. In JavaScript, you can perform it using the ** operator or Math.pow() method.
How to Break from forEach in JavaScript?
17 June 2023
There is no direct way to break from the forEach() function, however, there are some workarounds.
JavaScript: Add To Array Just If Element Doesn’t Exist
16 June 2023
In JavaScript, how to add an element to an array just if it does not yet exist within the given array or ignore the process if it already exists?
The Double Question Mark (Nullish Coalescing Operator) in JavaScript
14 June 2023
In JavaScript, the Double Question Mark (Nullish Coalescing Operator) is a special case from the OR Logical Operator (||). Let's introduce some use cases of it.
No posts found