Skip to content

Instantly share code, notes, and snippets.

@elusiveunit
elusiveunit / esrjl-editor-styles-refresh.php
Last active November 19, 2017 12:28
WordPress editor style cache refresh plugin
<?php
/**
* Plugin Name: Editor Styles Refresh
* Plugin URI: https://gist.github.com/elusiveunit/f0f728771de6647778fa
* Description: Adds file time query string to theme editor style URLs, to force cache busting when the file is changed.
* Author: Jens Lindberg
* Version: 0.1
* License: GPL-2.0+
*/
@elusiveunit
elusiveunit / firefox-privacy.md
Last active September 7, 2018 16:02 — forked from 0xDE57/config.md
Firefox about:config privacy settings

ABOUT

about:config settings to harden the Firefox browser. Privacy and performance enhancements.
To change these settings type 'about:config' in the url bar. Then search the setting you would like to change and modify the value. Some settings may break certain websites from functioning and rendering normally. Some settings may also make firefox unstable.

I am not liable for any damages/loss of data.

Not all these changes are necessary and will be dependent upon your usage and hardware. Do some research on settings if you don't understand what they do. These settings are best combined with your standard privacy extensions (HTTPS Everywhere, NoScript/Request Policy, uBlock origin, agent spoofing, Privacy Badger etc), and all plugins set to "Ask To Activate".

1: 日
2: 一
3: 国
4: 会
5: 人
6: 年
7: 大
8: 十
9: 二
10: 本
var str = 'class ಠ_ಠ extends Array {constructor(j = "a", ...c) {const q = (({u: e}) => {return { [`s${c}`]: Symbol(j) };})({});super(j, q, ...c);}}' +
'new Promise((f) => {const a = function* (){return "\u{20BB7}".match(/./u)[0].length === 2 || true;};for (let vre of a()) {' +
'const [uw, as, he, re] = [new Set(), new WeakSet(), new Map(), new WeakMap()];break;}f(new Proxy({}, {get: (han, h) => h in han ? han[h] ' +
': "42".repeat(0o10)}));}).then(bi => new ಠ_ಠ(bi.rd));';
try {
eval(str);
} catch(e) {
alert('Your browser does not support ES6!')
}
@elusiveunit
elusiveunit / anki-persistent-data.js
Last active August 29, 2022 22:31
Anki - persistent data between front and back
// Inspired by https://github.com/SimonLammer/anki-persistence
// A much dumber variant to reduce the amount of code on the card.
// Basically just native sessionStorage and a global object
// fallback with a matching API.
window.valueStore = (function (win) {
try {
return win.sessionStorage;
} catch (e) {}
win.vso = win.vso || {};