This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// あーだ遷移半自動化ブックマークレット | |
// original | |
(function(q,d){ | |
if(d[q](".result")!=null){ | |
d[q]('img[src^="http://twitter-badges"]').parentNode.click() | |
}else{ | |
d[q]("form[name=enter]").submit(); | |
} | |
}("querySelector",document)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Hoge{ | |
constructor(public x:number,public y:number){} | |
} | |
class Fuga{ | |
constructor(x:number,y:number){} | |
x:number; | |
y:number; | |
} | |
function f(v:Fuga){ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var replaceSoundPlayer = function(obj_element){ | |
var url=obj_element.getElementsByTagName("embed")[0].src, | |
el = document.createElement("iframe"), | |
parent = obj_element.parentNode; | |
el.src=url.replace(/^https?:\/\/player.soundcloud.com\/player.swf/,location.protocol+"//w.soundcloud.com/player/"); | |
el.width = obj_element.width; | |
el.height = obj_element.height; | |
parent.insertBefore(el,obj_element.nextSibling); | |
parent.removeChild(obj_element); | |
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// YouTubeの再生画面からBGMShareHouseにキューを投げるブックマークレット(非同期版) | |
// javascript:(function(h,d,e){e=d.createElement("script");e.src=h+"code.jquery.com/jquery-1.9.0.min.js";e.onload=function(){setTimeout(function(){jQuery.post(h+"bgm.tokor.org/query.php",{qmode:"new",qvalue:/v=(.{11})/.exec(location.href)[1]})},500);};d.body.appendChild(e)})("http://",document) | |
// コード削る前 | |
(function(){ | |
var url="http://code.jquery.com/jquery-latest.min.js"; | |
var el=document.createElement("script"); | |
el.src=url; | |
el.onload = function(){ | |
setTimeout(function(){ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Foo.prototype.f = ...でメソッドを追加するスタイル | |
var Foo = function(){}; | |
Foo.prototype.f = function(){ | |
console.log("foo"); | |
}; | |
Foo.prototype.g = function(){ | |
console.log("bar"); | |
}; | |
// Bar.prototype = { ... } でメソッドを追加するスタイルだと... |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @include https://*.google.co.jp/* | |
// ==/UserScript== | |
(function(){ | |
var f = function(){ | |
Array.prototype.forEach.apply(document.querySelectorAll( | |
'img[src^="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACwAAAAsCAIAAACR5s1WAAAAA3NCSVQICAjb4U/"]'), | |
[function(v){ | |
if(v.style.display!=="none"){ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// ==UserScript== | |
// @include https://webcatalog.circle.ms/Circle | |
// @include https://webcatalog.circle.ms/Circle?* | |
// ==/UserScript== | |
// | |
(function(){ | |
var script = document.createElement("script"); | |
script.textContent = "("+(function(){ | |
var last_href = ""; | |
var f = function(){ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var callcc = function(f){ | |
var c = new Continuation(); | |
return f(c); | |
}; | |
// Original code | |
// (let* ((yin ((lambda (cc) (newline) cc) | |
// (call/cc (lambda (bar) bar)))) | |
// (yang ((lambda (cc) (display "*") cc) | |
// (call/cc (lambda (foo) foo))))) |
OlderNewer