Last updated: 28/05/24
Make sure your computer is 64-bit! Arm64 works too!
Last updated: 28/05/24
Make sure your computer is 64-bit! Arm64 works too!
Starting a personal node project could be easy; starting a team node project could be challenging.
I Forked from https://gist.github.com/silver-xu/1dcceaa14c4f0253d9637d4811948437 and customize for myself.
In my experience, common mistakes developer make when starting a projects are:
/* | |
The MIT License (MIT) | |
Original work Copyright (c) 2014 Ismael Celis | |
Modified work Copyright 2022 Markus Bach | |
Permission is hereby granted, free of charge, to any person obtaining a copy | |
of this software and associated documentation files (the "Software"), to deal | |
in the Software without restriction, including without limitation the rights | |
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell |
#!/bin/sh | |
STAGED_FILES=$(git diff --cached --name-only --diff-filter=ACM | grep ".jsx\{0,1\}$") | |
if [[ "$STAGED_FILES" = "" ]]; then | |
exit 0 | |
fi | |
PASS=true |
await mongoose.connect(dbUrl, { | |
useNewUrlParser: true, | |
useUnifiedTopology: true, | |
useCreateIndex: true, | |
useFindAndModify: false, | |
}); | |
const connection = mongoose.connection; | |
connection.once("open", function() { |
(() => {
let { offsetWidth, offsetHeight } = document.documentElement;
let walker = document.createTreeWalker(document.body, NodeFilter.SHOW_ELEMENT);
while (walker.nextNode()) {
let bound = walker.currentNode.getBoundingClientRect();
let isWidthOverflow = bound.right > offsetWidth || bound.left < 0;
let isHeightOverflow = bound.bottom > offsetHeight || bound.top < 0;
// Youtube tutorial here: https://youtu.be/LDgPTw6tePk | |
// These functions are designed to be exported, but you could create a class instead. See tutorial video. | |
// #1 proper case | |
export const properCase = (string) => { | |
return `${string[0].toUpperCase()}${string.slice(1).toLowerCase()}`; | |
}; | |
version: '2' | |
services: | |
dind: | |
restart: always | |
privileged: true | |
volumes: | |
- /var/lib/docker | |
image: docker:17.09.0-ce-dind |