Skip to content

Instantly share code, notes, and snippets.

View cometkim's full-sized avatar

Hyeseong Kim cometkim

View GitHub Profile
@storycraft
storycraft / dmca-takedown-kakao.txt
Last active March 7, 2023 05:28
DMCA Takedown Notice [ref:00DA0000000K0A8.5004w000026Fag0:ref]
DMCA Takedown Notice
== Copyright owner: Kakao Corp.
== Name: An Chisu
== Company: Kakao Corp.
== Job title: IP Manager
== Email address: [email protected]
== Address: 7F N, H-Square, 235
== City: Pangyoyeok-ro, Bundang-gu, Seongnam-si

⚠️ Warning: this document is out of date.

For the most recent webpack5 instructions see MIGRATION.md.

Storybook experimental Webpack 5 support

Storybook 6.2 includes experimental Webpack 5 support. Webpack 5 brings a variety of performance improvements, as well as exciting new features like module federation. Here's a quick guide to get you going.

Intro

@sciyoshi
sciyoshi / esbuild-relay.js
Created February 19, 2021 16:34
Esbuild plugin for compiling relay queries
import { promises } from "fs";
import crypto from "crypto";
import path from "path";
import { print, parse } from "graphql";
const plugin = {
name: "relay",
setup: build => {
build.onLoad({ filter: /\.tsx$/, namespace: "" }, async args => {
let contents = await promises.readFile(args.path, "utf8");
declare interface CSS {
layoutWorklet: Worklet // eslint-disable-line no-undef
paintWorklet: Worklet // eslint-disable-line no-undef
animationWorklet: Worklet // eslint-disable-line no-undef
}
declare type ChildDisplay = "block" | "normal"
declare type LayoutSizingMode = "block-like" | "manual"
declare interface LayoutOptions {
@azlen
azlen / bulletpaths.js
Last active February 28, 2025 16:24
All Paths Lead to Roam
/*
* credit to Dhrumil Shah (@wandcrafting) and Robert Haisfield (@RobertHaisfield)
* for the original concept which was part of their RoamGames submission
* and can be found at: https://www.figma.com/file/5shwLdUCHxSaPNEO7pazbe/
*
*/
/* ======= OPTIONS ======== */
/* note: if you change these, reload the page to see the effect */
@kitten
kitten / README.md
Last active February 10, 2021 18:07
urql update: February 2021

urql update: February 2021

Note: This announcement is related to today's batch of released urql packages. You can see the release process and the changelogs here: urql-graphql/urql#1340

We have an entirely new release batch that we've just worked on. This batch includes some breaking changes and major releases, so we'd like to take a moment to talk about what has changed. It will luckily be surprisingly unsurprising and builds on the work that's already been ongoing for a while. Lastly we'll include a note on our upcoming roadmap, which we'll be kicking off soon.

@kiding
kiding / NoScrollOnInputFocusiOSSafari.html
Last active March 12, 2025 19:09
Preventing iOS Safari scrolling when focusing on input elements
<!--
When an input element gets focused, iOS Safari tries to put it in the center by scrolling (and zooming.)
Zooming can be easily disabled using a meta tag, but the scrolling hasn't been quite easy.
The main quirk (I think) is that iOS Safari changes viewport when scrolling; i.e., toolbars shrink.
Since the viewport _should_ change, it thinks the input _will_ move, so it _should_ scroll, always.
Even times when it doesn't need to scroll—the input is fixed, all we need is the keyboard—
the window always scrolls _up and down_ resulting in some janky animation.
However, iOS Safari doesn't scroll when the input **has opacity of 0 or is completely clipped.**
@seoh
seoh / fp-curriculum.md
Last active August 15, 2023 16:18
A functional programming curriculum

함수형 프로그래밍 커리큘럼

함수형 프로그래밍에 중점을 둔 스칼라 책들은 훌륭한게 많지만 초심자부터 전문가까지 단계별로 가이드할 수 있는 커리큘럼을 추천하려고한다.

  1. 초보자거나 스칼라 입문이라면:
  • 데이브 거넬과 노엘 웰시의 크리에이티브 스칼라(무료). 스칼라를 배우려는 입문자들을 위한 책이고 재미있다.
  • 노엘 웰시와 데이브 거널의 에센셜 스칼라(무료). 견고하고 성능좋고 스칼라다운 코드를 짜도록 도와준다. 다른 언어의 경험이 있는 개발자들을 대상
  1. 더 심도있는 개념을 원하면:
  • 폴 키우사노와 루나르 비아르드나손의 스칼라로 배우는 함수형 프로그래밍($36, 2.8만). 객체지향의 디자인패턴처럼 함수형 프로그래밍에서 자주 쓰이는 패턴인 데이터와 타입클래스들이 어떤 개념인지 직접 구현해보는 책. 스칼라 문법 정도는 익힌 개발자 대상.
@kyleshevlin
kyleshevlin / memoizedHandlers.js
Created January 22, 2021 00:26
Using React.useMemo to create a `handlers` object
// One of my new favorite React Hook patternms is to create handler
// functions for a custom hook using `React.useMemo` instead of
// `React.useCallback`, like so:
function useBool(initialState = false) {
const [state, setState] = React.useState(initialState)
// Instead of individual React.useCallbacks gathered into an object
// Let's memoize the whole object. Then, we can destructure the
// methods we need in our consuming component.
@leoh0
leoh0 / README.md
Last active July 18, 2024 06:44
containerd를 이용해서 standalone kubelet 사용하기

standalone-kubelet-with-containerd.md

가끔 kubernetes 같은건 너무 무거워서 단일 호스트에 docker만 띄워서 운영하는 경우같은걸 고민 하게 됩니다. 하지만 그냥 docker만 가지고 사용하면 컨테이너가 죽었을때 관리해 줘야 하는 불편함과 같이 기능을 보다 더 필요로 하게 됩니다. 그래서 이 방법을 소개해 드립니다.

이건 standalone kubelet 이라고 불리는 master 없이 node만 관리해주는 kubelet을 이용해서 container를 관리하는 방법입니다. 이건 k8s 초기 부터 원래 존재했던 컨셉이나 많이 알려져 있지 않아서 모르시는 분들이 많아서 이글을 작성해 봤습니다.

이 방법을 이용하면 실제 master 없이 kubelet 만으로 서비스를 할 수 있습니다. 컨테이너 자동 재시작, port forwarding, resource limit 등 기본적인 kubelet에서 제공하는 다양한 방법으로 컨테이너들을 관리 할 수 있습니다.