Skip to content

Instantly share code, notes, and snippets.

View SooJungChae's full-sized avatar

Soojung Chae SooJungChae

  • South Korea
View GitHub Profile
@CSTDev
CSTDev / auto-increment-version.sh
Last active October 23, 2024 23:42
Script that will find the last Git Tag and increment it. It will only increment when the latest commit does not already have a tag. By default it increments the patch number, you can tell it to change the major or minor versions by adding #major or #minor to the commit message.
#!/bin/bash
#get highest tag number
VERSION=`git describe --abbrev=0 --tags`
#replace . with space so can split into an array
VERSION_BITS=(${VERSION//./ })
#get number parts and increase last one by 1
VNUM1=${VERSION_BITS[0]}
@bradtraversy
bradtraversy / eslint_prettier_airbnb.md
Created July 19, 2019 17:54
ESLint, Prettier & Airbnb Setup

VSCode - ESLint, Prettier & Airbnb Setup

1. Install ESLint & Prettier extensions for VSCode

Optional - Set format on save and any global prettier options

2. Install Packages

npm i -D eslint prettier eslint-plugin-prettier eslint-config-prettier eslint-plugin-node eslint-config-node

[record] ๋ด„๋‚ ์˜ ๊ตฌ์งํ™œ๋™

Warning

๊ฐ ํšŒ์‚ฌ์˜ ๋ฉด์ ‘ ์ค‘์— ๋ฐ›์€ ๋ฌธ์ œ๋‚˜ ์งˆ๋ฌธ์— ๋Œ€ํ•ด์„œ๋Š” ์ƒ์„ธํžˆ ๊ธฐ์ˆ ํ•˜์ง€ ์•Š๋Š”๋‹ค. ๊ฐ ์‚ฌ๋‚ด (๋ณด์•ˆ) ๊ทœ์ •์„ ์œ„๋ฐ˜ํ•  ๊ฐ€๋Šฅ์„ฑ์ด ์žˆ๋‹คโ€ฆโ€‹. ์ž์„ธํžˆ ์•Œ๋ ค์ฃผ์ง€ ๋ชปํ•ด์„œ ๋ฏธ์•ˆํ•˜๋‹ค.

์‹œ์ž‘

@faressoft
faressoft / dom_performance_reflow_repaint.md
Last active February 10, 2025 17:21
DOM Performance (Reflow & Repaint) (Summary)

DOM Performance

Rendering

  • How the browser renders the document
    • Receives the data (bytes) from the server.
    • Parses and converts into tokens (<, TagName, Attribute, AttributeValue, >).
    • Turns tokens into nodes.
    • Turns nodes into the DOM tree.
  • Builds CSSOM tree from the css rules.
@avinmathew
avinmathew / index.jsx
Created August 8, 2017 11:54
Multiple layouts with React Router v4
import React from "react"
import { Route, Switch } from "react-router-dom"
const AppRoute = ({ component: Component, layout: Layout, ...rest }) => (
<Route {...rest} render={props => (
<Layout>
<Component {...props} />
</Layout>
)} />
)
@moimikey
moimikey / after.js
Last active June 5, 2023 04:50
object literals for redux reducers
// O(1)
const todo = (state, action) => {
const actions = {
ADD_TODO: () => {
return {
id: action.id,
text: action.text,
completed: false
}
},
@goesang
goesang / quickSort.js
Created June 23, 2015 14:16
ํ€ต ์ •๋ ฌ ์ž๋ฐ”์Šคํฌ๋ฆฝํŠธ ๊ฐ„๋‹จ ๋ฒ„์ ผ
function quickSort(arr){
if(arr.length < 2)
return arr;
var pivot = arr[Math.floor(arr.length/2)];
var middle = arr.filter(function (data) {return data == pivot;});
var lows = quickSort(arr.filter(function (data) {return data < pivot;}));
var highs = quickSort(arr.filter(function (data) {return data > pivot;}));
@sooop
sooop / hangulSound.js
Created February 15, 2013 06:48
ํ•œ๊ธ€ ์ดˆ/์ค‘/์ข…์„ฑ์„ ๊ตฌํ•˜๋Š” ์ž๋ฐ”์Šคํฌ๋ฆฝํŠธ ํ•จ์ˆ˜
/**
์ดˆ์„ฑ ์ค‘์„ฑ ์ข…์„ฑ ๋ถ„๋ฆฌ ํ•˜๊ธฐ
์œ ๋‹ˆ์ฝ”๋“œ ํ•œ๊ธ€์€ 0xAC00 ์œผ๋กœ๋ถ€ํ„ฐ
์ดˆ์„ฑ 19๊ฐœ, ์ค‘์ƒ21๊ฐœ, ์ข…์„ฑ28๊ฐœ๋กœ ์ด๋ฃจ์–ด์ง€๊ณ 
์ด๋“ค์„ ์กฐํ•ฉํ•œ 11,172๊ฐœ์˜ ๋ฌธ์ž๋ฅผ ๊ฐ–๋Š”๋‹ค.
ํ•œ๊ธ€์ฝ”๋“œ์˜ ๊ฐ’ = ((์ดˆ์„ฑ * 21) + ์ค‘์„ฑ) * 28 + ์ข…์„ฑ + 0xAC00
(0xAC00์€ 'ใ„ฑ'์˜ ์ฝ”๋“œ๊ฐ’)
@MohamedAlaa
MohamedAlaa / tmux-cheatsheet.markdown
Last active April 16, 2025 19:00
tmux shortcuts & cheatsheet

tmux shortcuts & cheatsheet

start new:

tmux

start new with session name:

tmux new -s myname