A tweet-sized debugger for visualizing your CSS layouts. Outlines every DOM element on your page a random (valid) CSS hex color.
One-line version to paste in your DevTools
Use $$
if your browser aliases it:
~ 108 byte version
$ ffmpeg -i input.mp4 -vcodec h264 -acodec mp2 output.mp4 |
import { Component } from "React"; | |
export var Enhance = ComposedComponent => class extends Component { | |
constructor() { | |
this.state = { data: null }; | |
} | |
componentDidMount() { | |
this.setState({ data: 'Hello' }); | |
} | |
render() { |
Replace all instances of <polyline
with <path
and points="
with d="M
.
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
<svg version="1.1" id="Layer_1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" x="0px" y="0px" width="1000px" height="1000px" viewBox="0 0 1000 1000" enable-background="new 0 0 1000 1000" xml:space="preserve">
-<polyline fill="#FFFFFF" stroke="#000000" stroke-miterlimit="10" points="100.712,141.534 582.904,227.835 425.37,478.521
+
To install, you need to have the WordPress i18n library on your computer. Check it out using SVN:
sudo svn co http://i18n.svn.wordpress.org/tools/trunk/ /usr/lib/wpi18n
You don't have to put the library in /usr/lib/wpi18n
, but if you don't put it there, make sure to set the $WP_I18N_LIB
environment variable in your .bashrc
or .bash_profile
file (with no trailing slash):
export WP_I18N_LIB="/path/to/i18n/lib"
This article has been given a more permanent home on my blog. Also, since it was first written, the development of the Promises/A+ specification has made the original emphasis on Promises/A seem somewhat outdated.
Promises are a software abstraction that makes working with asynchronous operations much more pleasant. In the most basic definition, your code will move from continuation-passing style:
getTweetsFor("domenic", function (err, results) {
// the rest of your code goes here.
This was useful for me when we created a new branch for a new major release, but were still working on our current version as well. I cloned our repo again and kept the new project on our new branch, but also wanted to get my stashes there.
git stash show -p > patch
You'll have to specify your stash and name your file whatevery you want. Do this for as all your stashes, and you'll have patch files in your pwd.
(function(global) { | |
var silpUrl = '//s3-eu-west-1.amazonaws.com/silp.shootitlive.com/js/silp.min.js'; | |
// Globals | |
if(!global.Silp) { global.Silp = {}; }; | |
var Silp = global.Silp; | |
// To keep track of which embeds we have already processed | |
if(!Silp.foundEls) Silp.foundEls = []; |