🚚 The bookmarklet has moved to https://github.com/bramus/mastodon-profile-redirect/
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!') | |
} |
Inspired by this issue, with these instructions you should be able to get Babel transpiling your JS in Sails JS for the client side.
- Install Grunt Babel
npm install --save grunt-babel
- Create a
babel.js
file undertasks/config
and add something like the following:
module.exports = function(grunt) {
grunt.config.set('babel', {
dev: {
# How to use PG Point type in SQAlchemy | |
# | |
# Most of the code comes from here: | |
# http://initd.org/psycopg/docs/advanced.html#adapting-new-types | |
import re | |
import sqlalchemy | |
import psycopg2 | |
from psycopg2.extensions import adapt, register_adapter, AsIs |
⇐ back to the gist-blog at jrw.fi
Or, 16 cool things you may not have known your stylesheets could do. I'd rather have kept it to a nice round number like 10, but they just kept coming. Sorry.
I've been using SCSS/SASS for most of my styling work since 2009, and I'm a huge fan of Compass (by the great @chriseppstein). It really helped many of us through the darkest cross-browser crap. Even though browsers are increasingly playing nice with CSS, another problem has become very topical: managing the complexity in stylesheets as our in-browser apps get larger and larger. SCSS is an indispensable tool for dealing with this.
This isn't an introduction to the language by a long shot; many things probably won't make sense unless you have some SCSS under your belt already. That said, if you're not yet comfy with the basics, check out the aweso
<?php | |
/** | |
* External authentication plugin interface to ExpressionEngine 2.2+ | |
* | |
* Basic setup: | |
* - Save this file into extensions/ExtExpressionEngineAuthDB/ExtExpressionEngineAuthDB.php | |
* - Insert LocalSettings.php requirements, see below for what they are. | |
* | |
* This extension is a derivation of http://www.mediawiki.org/wiki/Extension:ExtAuthDB | |
* |
@media (min--moz-device-pixel-ratio: 1.5), | |
(-o-min-device-pixel-ratio: 3/2), | |
(-webkit-min-device-pixel-ratio: 1.5), | |
(min-device-pixel-ratio: 1.5), | |
(min-resolution: 1.5dppx) { | |
/* "retina" styles */ | |
} |
# -*- coding: utf-8 -*- | |
require_relative 'twitterbot' | |
Twitter.configure {|config| | |
config.consumer_key = 'consumer key' | |
config.consumer_secret = 'consumer secret' | |
config.oauth_token = 'oauth token' | |
config.oauth_token_secret = 'oauth token secret' | |
} |
// Lefalet shortcuts for common tile providers - is it worth adding such 1.5kb to Leaflet core? | |
L.TileLayer.Common = L.TileLayer.extend({ | |
initialize: function (options) { | |
L.TileLayer.prototype.initialize.call(this, this.url, options); | |
} | |
}); | |
(function () { | |