Skip to content

Instantly share code, notes, and snippets.

View magichim's full-sized avatar
🎯
Focusing

Songwon Park magichim

🎯
Focusing
View GitHub Profile
@michaellihs
michaellihs / tmux-cheat-sheet.md
Last active May 3, 2024 10:55
tmux Cheat Sheet
@betweenbrain
betweenbrain / read-files.js
Created December 5, 2016 22:35
Node.js read multiple files, write into one
var fs = require('fs');
var Promise = require('promise');
var promises = [];
var readline = require('readline');
var readFile = function (file) {
return new Promise(function (resolve, reject) {
var lines = [];
var rl = readline.createInterface({
input: fs.createReadStream('./logs/' + file)
@faressoft
faressoft / dom_performance_reflow_repaint.md
Last active March 24, 2024 11:41
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.
@bastienrobert
bastienrobert / README.md
Last active April 29, 2024 03:24
Script to open chrome with specific URL gived in params

OpenChrome

Inspired by Create React App

This script is checking in every chrome window if there's a tab with the URL gived in params:

  • If there's one: It opens chrome in first-ground and show the good chrome window with the good tab
  • If there's multiples: Same behavior but it use the first tab found
  • If there's not: It launch chrome (if it's not open) and create a new tab with the given URL

How it works

osascript openChrome.scpt YOUR_FORMATTED_URL

@Astro36
Astro36 / rust-ffi-tutorial.md
Last active May 22, 2023 11:15
Node.js에서 FFI로 Rust를 이용해보자

Node.js에서 FFI로 Rust를 이용해보자

소개

Rust는 성능이 우수한 로우 레벨 프로그래밍 언어 중 하나입니다. 또한, 비용 없는 추상화, 메모리 안정성, 데이터 레이스 없는 스레딩 등등을 지원하며 C++에 비해 문법도 간결합니다. 이러한 장점의 Rust를 Node와 결합시켜 사용한다면, Node의 부족한 성능을 메꿀 수 있습니다. Node에서 Rust에서 작성한 함수를 호출하기 위해서는 FFI(Foreign function interface, 외부 함수 인터페이스)를 사용해야 합니다. 아래는 준비물입니다.

준비물