Skip to content

Instantly share code, notes, and snippets.

Andre AndreLion

Block or report user

Report or block AndreLion

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View press.one
{"sig":"555b05d652a7ad1cd6ba3b6facdae398d3aca3628ea5e753d67862a9046adda81b6e21809012452b375d7c80935d5f0d006b5711184e081e65359d798d831bb20","msghash":"f4581126ec0a3f9299fab2cfb0358136cd6f0f8f0ff665adf24933fb3da2e219"}
@AndreLion
AndreLion / shortcut.js
Last active Aug 29, 2015
轻单JK快捷键
View shortcut.js
(function(){
var style = document.createElement('style');
style.innerHTML = '.container ol.items li .title[shortcut] { border-color:#66afe9;box-shadow:inset 0 1px 1px rgba(0,0,0,.075),0 0 8px rgba(102,175,233,.6); }';
document.head.appendChild(style);
var length = document.querySelector('ol.items').children.length;
var index = 0;
var inc = function(){
return index >= length ? index = length : index++;
}
@AndreLion
AndreLion / GenerateDNSPrefetchVM.java
Created Jul 10, 2013
抓取某些页面引用的资源文件的域名,并生成固定格式的vm文件。
View GenerateDNSPrefetchVM.java
import java.io.*;
import java.io.BufferedReader;
import java.io.ByteArrayInputStream;
import java.io.File;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.IOException;
import java.net.HttpURLConnection;
import java.net.URL;
import java.util.ArrayList;
View jsperf-bookmarklet.js
(function(){
var key = localStorage.wpt_key;
if (!key) {
var prompt = window.__proto__.prompt;
key = prompt('Your WebPagetest API key, please?');
if (!key) {
return gameOver();
}
localStorage.wpt_key = key;
You can’t perform that action at this time.