Skip to content

Instantly share code, notes, and snippets.

View YuerLee's full-sized avatar

Yuer Lee YuerLee

  • Tradebeyond (former CBX Software)
  • Taiwan
  • 00:11 (UTC +08:00)
  • LinkedIn in/yuerlee
View GitHub Profile
@paulirish
paulirish / what-forces-layout.md
Last active May 11, 2025 01:28
What forces layout/reflow. The comprehensive list.

What forces layout / reflow

All of the below properties or methods, when requested/called in JavaScript, will trigger the browser to synchronously calculate the style and layout*. This is also called reflow or layout thrashing, and is common performance bottleneck.

Generally, all APIs that synchronously provide layout metrics will trigger forced reflow / layout. Read on for additional cases and details.

Element APIs

Getting box metrics
  • elem.offsetLeft, elem.offsetTop, elem.offsetWidth, elem.offsetHeight, elem.offsetParent
@developius
developius / README.md
Last active March 14, 2025 17:38
Setup SSH keys for use with GitHub/GitLab/BitBucket etc
@dwarcher
dwarcher / _debugger.ejs
Created March 19, 2015 14:43
Dead simple way to debug print in HARP.js
<script>
console.log("--- HARP Debugger --");
console.log(<%- JSON.stringify(inspect) %>);
// Just check your console in chrome to see and inspect the variable.
</script>
@jaceju
jaceju / web_development_with_laravel_5.md
Last active November 1, 2024 08:20
Laravel 5 測試起手式

Web Development with Laravel 5

目標

如何在開發的過程中加入測試。

  1. Model
  2. Repository
  3. Controller
  4. Auth
@vitorbritto
vitorbritto / rm_mysql.md
Last active May 6, 2025 19:35
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
    

側欄

folder:

    "bold_folder_labels": true,

編輯區

@nl5887
nl5887 / transfer.fish
Last active July 30, 2024 09:21
Bash and zsh alias for transfer.sh. Transfers files and directories to transfer.sh.
function transfer
if test (count $argv) -eq 0
echo "No arguments specified. Usage:\necho transfer /tmp/test.md\ncat /tmp/test.md | transfer test.md"
return 1
end
## get temporarily filename, output is written to this file show progress can be showed
set tmpfile ( mktemp -t transferXXX )
## upload stdin or file
@asfdfdfd
asfdfdfd / MegaRasterize.js
Last active July 23, 2021 15:19
Adobe Illustrator CS6 script that rasterizes every GroupItem from the first layer of active document to the separate png file.
function captureImage(fileName, document, clipRect) {
var fileOutput = new File("/tmp/exportpng/" + fileName);
var imageCaptureOptions = new ImageCaptureOptions();
imageCaptureOptions.resolution = 300;
imageCaptureOptions.transparency = true;
document.imageCapture(fileOutput, clipRect, imageCaptureOptions);
}
@staltz
staltz / introrx.md
Last active May 9, 2025 12:50
The introduction to Reactive Programming you've been missing
@visioncan
visioncan / CasksInstall.sh
Last active December 29, 2021 01:56
CasksInstall
#!/bin/bash
# xcode command tool
xcode-select --install
# check
xcode-select -p
# homebrew
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"