Skip to content

Instantly share code, notes, and snippets.

View crazcdll's full-sized avatar

crazcdll crazcdll

  • 美团
  • Beijing
View GitHub Profile
var CryptoJS = require('crypto-js')
var request = require('request-promise')
/*
* npm install crypto-js request-promise request
* node wx_t1t_hack.js
*/
// export function testEncription(msg, fullKey) {
// var fullKey = fullKey.slice(0, 16)
@paulirish
paulirish / what-forces-layout.md
Last active November 24, 2025 13:41
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
@famousgarkin
famousgarkin / powershell-proxy-set-clear.ps1
Last active July 24, 2024 17:04
PowerShell Set-Proxy, Clear-proxy
# NOTE: registry keys for IE 8, may vary for other versions
$regPath = 'HKCU:\Software\Microsoft\Windows\CurrentVersion\Internet Settings'
function Clear-Proxy
{
Set-ItemProperty -Path $regPath -Name ProxyEnable -Value 0
Set-ItemProperty -Path $regPath -Name ProxyServer -Value ''
Set-ItemProperty -Path $regPath -Name ProxyOverride -Value ''
[Environment]::SetEnvironmentVariable('http_proxy', $null, 'User')
@geekdada
geekdada / whitelist
Last active April 27, 2016 07:40
域名白名单(GoagentX 导入)
*.cn DirectConnection
.0x110.com DirectConnection
.10010.com DirectConnection
.10050.net DirectConnection
.115.com DirectConnection
.115img.com DirectConnection
.123cha.com DirectConnection
.126.com DirectConnection
.126.net DirectConnection
.163.com DirectConnection
@nightire
nightire / 解决 Git 在 windows 下中文乱码的问题.md
Last active August 7, 2025 04:14
解决 Git 在 windows 下中文乱码的问题

解决 Git 在 windows 下中文乱码的问题

原因

中文乱码的根源在于 windows 基于一些历史原因无法全面支持 utf-8 编码格式,并且也无法通过有效手段令其全面支持。

解决方案

  1. 安装