Skip to content

Instantly share code, notes, and snippets.

View pocojang's full-sized avatar
๐Ÿข

Poco pocojang

๐Ÿข
View GitHub Profile
@pocojang
pocojang / reactHoc.js
Created December 20, 2019 09:31
React HOC ์ปดํฌ๋„ŒํŠธ
const Foo = ({ result }) => <ResultComponent result={result} />;
const withRequest = BaseComponent => ({ bar, ...props }) => {
const { result, loading, error } = useRequest(bar);
return (
<BaseComponent {...props} result={result} loading={loading} error={error} />
);
};
const withError = branch(({ error }) => error, ErrorComponent);
const withLoading = branch(({ loading }) => loading, LoadingComponent);
export default compose(
@pocojang
pocojang / README-Template.md
Created February 16, 2020 07:15 — forked from PurpleBooth/README-Template.md
A template to make good README.md

Project Title

One Paragraph of project description goes here

Getting Started

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes. See deployment for notes on how to deploy the project on a live system.

Prerequisites

@pocojang
pocojang / React-Hooks.js
Created June 5, 2020 07:20 — forked from craigtaub/React-Hooks.js
Nested React Hooks
// Engine
const React = {
index: 0,
state: [],
useEffect: (callback, dependencies) => {
const cachedIndex = React.index;
const hasChanged = dependencies !== React.state[cachedIndex];
if (dependencies === undefined || hasChanged) {
callback();
@pocojang
pocojang / .eslintignore
Created October 27, 2020 06:31 — forked from RyanHirsch/.eslintignore
Typescript + Jest + ESLint + Tailwind
.next
__generated__
@pocojang
pocojang / dom_performance_reflow_repaint.md
Created April 28, 2022 12:43 — forked from faressoft/dom_performance_reflow_repaint.md
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.
@pocojang
pocojang / 2023-05-21-2016-to-2023-fe.md
Last active November 22, 2024 10:05
2016๋…„์— FE๋ฅผ ๋ฐฐ์šฐ๋Š” ๊ธฐ๋ถ„, 2023๋…„์— FE๋ฅผ ๋ฐฐ์šฐ๋Š” ๊ธฐ๋ถ„

์‹œ์ž‘ํ•˜๋ฉฐ

์š”์ฆ˜ ๋”ฐ๋ผ ๊ณผ๊ฑฐ ์œ ํ–‰ํ–ˆ๋˜ 2016๋…„์— ์ž๋ฐ”์Šคํฌ๋ฆฝํŠธ๋ฅผ ๋ฐฐ์šฐ๋Š” ๊ธฐ๋ถ„์ด๋ผ๋Š” ๊ธ€์ด ๋– ์˜ค๋ฅธ๋‹ค.
๊ทธ๋•Œ๋Š” ๊ผฌ๊ผฌ๋งˆ ์‹ ์ž… ๊ฐœ๋ฐœ์ž์˜€๊ณ  ์–ด์ฐจํ”ผ ๊ธ€์„ ๋ด๋„ ์•„๋ฌด๋Ÿฐ ๋‚ด์šฉ๋„ ์ดํ•ดํ•  ์ˆ˜ ์—†์—ˆ๊ณ  ์˜คํžˆ์—ฌ ์™ธ๊ณ„์–ด์— ๊ฐ€๊น๊ฒŒ ๋ณด์˜€์—ˆ๋Š”๋ฐ ์š”์ฆ˜์€ ์–ผ์ถ” ์•„.. ์ด๋Ÿฐ ์‹œ์ ˆ์ด ์žˆ์—ˆ๊ตฌ๋‚˜ ์ƒˆ์‚ผ ๋งŽ์€ ์ƒ๊ฐ์ด ๋“ ๋‹ค.

ํ˜„์žฌ 2023๋…„์ด ๋œ ์ง€๊ธˆ ํ”„๋ก ํŠธ์—”๋“œ ๊ฐœ๋ฐœ์ž๋ฅผ ๊ฟˆ๊พธ๋Š” ์–ด๋ฆฐ ํ•™์ƒ๋“ค๋„ ์‹ ์ž… ๊ฐœ๋ฐœ์ž๋“ค๋„ ์ •๋ง ๋งŽ์•„์กŒ๋‹ค.
๊ทธ๋“ค๊ณผ ๋น„๊ตํ•˜๋ฉด ๋‚œ ๋จผ์ € ์‹œ์ž‘ํ•œ๊ฒŒ ์ „๋ถ€์ธ๋ฐ ์กฐ๊ธˆ์€ ๋” ์‰ฝ๊ฒŒ ์‹œ์ž‘ํ•œ๊ฒŒ ์•„๋‹๊นŒ ํ•ญ์ƒ ๋ฐ˜์„ฑํ•˜๊ฒŒ ๋œ๋‹ค. ์ด ๊ธ€๋กœ ๊ทธ๊ฐ„ ๋А๊ผˆ๋˜ ์‹œ๋Œ€์˜ ๋ณ€ํ™”๋ฅผ ์ž‘์„ฑํ•˜๊ณ  ํ•œ๋ฒˆ ์ •๋ฆฌํ•ด๋ณด๊ณ ์ž ํ•œ๋‹ค.

>์—ฐ๋Œ€ ๋ณ„ ํƒ€์ž„๋ผ์ธ์„ ๋ชฉ์ฐจ๋กœ ์ด ๊ธ€์„ ์ž‘์„ฑํ–ˆ์œผ๋ฉฐ ๊ธฐ์ˆ  ์ˆ˜์ค€์ด๋‚˜ ์‹œ๊ธฐ์˜ ์–ด๊ธ‹๋‚จ์ด ์žˆ์„ ์ˆ˜๋Š” ์žˆ์Šต๋‹ˆ๋‹ค.