Skip to content

Instantly share code, notes, and snippets.

View magichim's full-sized avatar
๐ŸŽฏ
Focusing

Songwon Park magichim

๐ŸŽฏ
Focusing
View GitHub Profile
@toy-crane
toy-crane / toss-frontend-rules.mdc
Last active August 12, 2025 00:45
ํ† ์Šค ํ”„๋ก ํŠธ์—”๋“œ ๊ฐ€์ด๋“œ๋ผ์ธ ๊ธฐ๋ฐ˜์œผ๋กœ ๋งŒ๋“  Cursor rule
# Frontend Design Guideline
This document summarizes key frontend design principles and rules, showcasing
recommended patterns. Follow these guidelines when writing frontend code.
# Readability
Improving the clarity and ease of understanding code.
@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, ์™ธ๋ถ€ ํ•จ์ˆ˜ ์ธํ„ฐํŽ˜์ด์Šค)๋ฅผ ์‚ฌ์šฉํ•ด์•ผ ํ•ฉ๋‹ˆ๋‹ค. ์•„๋ž˜๋Š” ์ค€๋น„๋ฌผ์ž…๋‹ˆ๋‹ค.

์ค€๋น„๋ฌผ

@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

@faressoft
faressoft / dom_performance_reflow_repaint.md
Last active July 16, 2025 13:01
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.
@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)
@michaellihs
michaellihs / tmux-cheat-sheet.md
Last active August 4, 2025 13:24
tmux Cheat Sheet
@Pusnow
Pusnow / ํ•œ๊ธ€๊ณผ์œ ๋‹ˆ์ฝ”๋“œ.md
Last active July 15, 2025 01:14
ํ•œ๊ธ€๊ณผ ์œ ๋‹ˆ์ฝ”๋“œ

ํ•œ๊ธ€๊ณผ ์œ ๋‹ˆ์ฝ”๋“œ

์œ ๋‹ˆ์ฝ”๋“œ์—์„œ ํ•œ๊ธ€์„ ์–ด๋–ป๊ฒŒ ๋‹ค๋ฃจ๋Š”์ง€๋ฅผ ์ •๋ฆฌํ•˜์˜€๋‹ค.

์œ ๋‹ˆ์ฝ”๋“œ

  • ์œ ๋‹ˆ์ฝ”๋“œ(Unicode)๋Š” ์ „ ์„ธ๊ณ„์˜ ๋ชจ๋“  ๋ฌธ์ž๋ฅผ ์ปดํ“จํ„ฐ์—์„œ ์ผ๊ด€๋˜๊ฒŒ ํ‘œํ˜„ํ•˜๊ณ  ๋‹ค๋ฃฐ ์ˆ˜ ์žˆ๋„๋ก ์„ค๊ณ„๋œ ์‚ฐ์—… ํ‘œ์ค€ (์œ„ํ‚ค ๋ฐฑ๊ณผ)
  • ๋‹จ์ˆœํžˆ ๋ฌธ์ž๋งˆ๋‹ค ๋ฒˆํ˜ธ๋ฅผ ๋ถ™์ž„
  • ๊ณ„์† ์—…๋ฐ์ดํŠธ๋˜๋ฉฐ ํ˜„์žฌ๋Š” Unicode Version 9.0.0 ์ด ์ตœ์‹ ์ด๋‹ค.

UTF

  • ์œ ๋‹ˆ์ฝ”๋“œ๋ฅผ ์‹ค์ œ ํŒŒ์ผ ๋“ฑ์— ์–ด๋–ป๊ฒŒ ๊ธฐ๋กํ•  ๊ฒƒ์ธ์ง€๋ฅผ ํ‘œ์ค€ํ™”ํ•œ ๊ฒƒ์ด๋‹ค.
@mjohnsullivan
mjohnsullivan / http_server.rs
Last active May 5, 2025 15:14
Simple HTTP server example for Rust
// Updated example from http://rosettacode.org/wiki/Hello_world/Web_server#Rust
// to work with Rust 1.0 beta
use std::net::{TcpStream, TcpListener};
use std::io::{Read, Write};
use std::thread;
fn handle_read(mut stream: &TcpStream) {
let mut buf = [0u8 ;4096];
@MihaelIsaev
MihaelIsaev / CameraViewController.swift
Created April 16, 2015 19:30
This is the example of camera view for iOS written in Swift
import UIKit
import AVFoundation
class ViewController: UIViewController, AVCaptureMetadataOutputObjectsDelegate {
@IBOutlet weak var myView: UIView!
var session: AVCaptureSession?
var device: AVCaptureDevice?
var input: AVCaptureDeviceInput?
@vitorbritto
vitorbritto / rm_mysql.md
Last active July 28, 2025 19:10
Remove MySQL completely from Mac OSX

Remove MySQL completely

  1. Open the Terminal

  2. Use mysqldump to backup your databases

  3. Check for MySQL processes with: ps -ax | grep mysql

  4. Stop and kill any MySQL processes

  5. Analyze MySQL on HomeBrew:

    brew remove mysql