Yarn/npm cheatsheetYarn Commandnpm EquivalentDescription yarn initnpm initInitializes a new project yarn installnpm installInstalls dependencies based on the package.json file yarn add <package>npm install <package>Adds a package as a project dependency yarn remo...May 19, 2023·6 min read
Most Used Git Commandsgit init # initialize directory as git repository git clone curl> # copying git repository from hosted url to local machine git status # show modified files in current directory git log # view your commit history git add -A # add changed files into y...May 6, 2023·4 min read
Chrome Extensions I useCalendlySchedule meetings without the hassle.ColorZillaAdvanced Eyedropper, Color Picker, Gradient Generator and other colorful goodiesCSS PeeperExtract CSS and build beautiful styleguides.CSS UsedGet all css rules used by the selected DOM and its de...Apr 18, 2023·4 min read
React Hooks part 1useState and useEffect import React from "react"; import { useState, useEffect } from "react"; function WindowSizeList({ url }) { const [windowWidth, setWindowWidth] = useState(window.innerWidth) const [items, setItems] = useState([]) c...Mar 24, 2023·3 min read
JS Mini Challenges Week 1Guess the outputs without executing the code var foo = function(){ var args = Array.prototype.slice.call(arguments); console.log(args[1]) } foo(1,2,4) //? const obj1 = { a: 5, b: { c: 6 } } const obj2 = Object.assign({},...Mar 23, 2023·2 min read
Things to remember about JavaScript ForEach LoopCan’t Skip an Iteration with "Continue" const arr = [1, 2, 3, 4, 5, 6, 7] arr.forEach((val) => { if (val === 3) { continue; } console.log("current: ", val) } ) // SyntaxError: Unsyntactic continue Can’t End A Loop Early with "Br...Mar 22, 2023·1 min read