Skip to content

Instantly share code, notes, and snippets.

View Patrick-Jabba's full-sized avatar
🤓
Full Stack Developer Next.Js

Patrick Monteiro Fischer Patrick-Jabba

🤓
Full Stack Developer Next.Js
View GitHub Profile
export function getDiffTimeBetweenCurrentDate (dateString = '', now = new Date()) {
const dayInMilliseconds = 86400000
if ([null, undefined, false, true].includes(dateString)) {
return dateString
}
const date = new Date(dateString)
const isInvalidDate = isNaN(date.getTime())
if (isInvalidDate) {
return dateString
@diego3g
diego3g / NODE.md
Last active April 29, 2025 16:13
VSCode Settings (Updated)

⚠️ Note!

With VSCode version 1.94, the APC extension broke and there is no fix yet.

So, for those having issues with APC after the VSCode update, I recommend downloading the previous version of VSCode for now (https://code.visualstudio.com/updates/v1_93) and setting updates to manual by adding this to the editor's configuration:

"update.mode": "manual",