Skip to content

Instantly share code, notes, and snippets.

View devstefancho's full-sized avatar
🐉
Working in the office

DevStefanCho devstefancho

🐉
Working in the office
View GitHub Profile
@devstefancho
devstefancho / .gitmessage.txt
Created September 16, 2023 15:30
git message
# [[ Title ]]
# <type>(<scope>): <subject>
# feat: new feature for the user, not a new feature for build script
# fix: bug fix for the user, not a fix to a build script
# docs: changes to the documentation
# style: formatting, missing semi colons, etc; no production code change
# refactor: refactoring production code, eg. renaming a variable
# test: adding missing tests, refactoring tests; no production code change
# chore: updating grunt tasks etc; no production code change
@devstefancho
devstefancho / leetcode-cli.py
Last active June 13, 2023 15:22
Python script for easy to create, test, submit to leetcode
import subprocess
from enum import Enum
class Command(Enum):
LEETCODE_CLI = "leetcode"
SHOW = "show" # 생성
TEST = "test" # 테스트
SUBMIT = "submit" # 제출
var mediaJSON = { "categories" : [ { "name" : "Movies",
"videos" : [
{ "description" : "Big Buck Bunny tells the story of a giant rabbit with a heart bigger than himself. When one sunny day three rodents rudely harass him, something snaps... and the rabbit ain't no bunny anymore! In the typical cartoon tradition he prepares the nasty rodents a comical revenge.\n\nLicensed under the Creative Commons Attribution license\nhttp://www.bigbuckbunny.org",
"sources" : [ "http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/BigBuckBunny.mp4" ],
"subtitle" : "By Blender Foundation",
"thumb" : "images/BigBuckBunny.jpg",
"title" : "Big Buck Bunny"
},
{ "description" : "The first Blender Open Movie from 2006",
"sources" : [ "http://commondatastorage.googleapis.com/gtv-videos-bucket/sample/ElephantsDream.mp4" ],
@devstefancho
devstefancho / react-check-re-render-state.js
Last active June 25, 2020 16:00
When you want to find a state which one is affecting in re-rendering your component
// React-Hooks
import {useEffect, useRef} from 'react'
// Suppose you have three state : restaurant, address, weather. and you want to find which state is affecting in rendering
console.log('restaurant' , restaurant);
useEffect(()=>{
console.log('restaurant effect', restaurant);
},[restaurant]);
console.log('address' , address);