更新: | 2024-05-20 |
---|---|
作者: | @voluntas |
バージョン: | 2024.1 |
URL: | https://voluntas.github.io/ |
This file contains hidden or 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 reg = /^\w/y; | |
reg.exec('xyz'); // => x | |
reg.exec('xyz'); // => y | |
reg.exec('xyz'); // => z | |
reg.exec('xyz'); // => null | |
reg.exec('xyz'); // => x | |
reg.lastIndex = 2; | |
reg.exec('xyz'); // => z |
This file contains hidden or 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 table = document.querySelectorAll('table')[0]; | |
var links = Array.prototype.map.call(table.querySelectorAll('a'), function(a) {return a.href}); | |
var timer = window.setInterval(function() { | |
document.body.innerHTML = "<img src='"+links[parseInt(Math.random()*links.length)]+"'>"; | |
}, 10000); |
This file contains hidden or 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== | |
// @name NumakuroOnGyazoNinjaEditor | |
// @namespace userjs.pastak.com.gyazo | |
// @description Gyazo Ninjaの編集機能でヌマクロー画像を使う | |
// @include https://gyazo.com/* | |
// ==/UserScript== | |
(function (callback) { | |
var script = document.createElement("script"); | |
script.textContent = "$(" + callback.toString() + ");"; | |
document.body.appendChild(script); |
This file contains hidden or 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
#!/bin/bash -e | |
id=$(chrome-cli list links | grep "chrome://extensions/" | awk '{print $1}' | sed -E "s/^\[([0-9]+)\]$/\1/g") | |
if [[ -n $id ]] ; then | |
chrome-cli reload -t "$id" | |
else | |
chrome-cli open "chrome://extensions" | |
fi |
OlderNewer