Install FFmpeg with homebrew. You'll need to install it with a couple flags for webm and the AAC audio codec.
brew install ffmpeg --with-libvpx --with-libvorbis --with-fdk-aac --with-opus
const analyticsId = 'UA-xxxxxxxxx-x' | |
addEventListener('fetch', event => { | |
event.respondWith(handleRequest(event)) | |
}) | |
/** | |
* Check request object for Googlebot UA to send tracking data | |
* @param {Event} event | |
*/ |
<?php | |
/********* DO NOT COPY THE PARTS ABOVE THIS LINE *********/ | |
/* Remove Date Meta Tags Output by Yoast SEO | |
* Credit: Yoast development team | |
* Last Tested: Apr 09 2019 using Yoast SEO 10.1.3 on WordPress 5.1.1 | |
* For Yoast SEO 14.0 or newer, please see https://yoast.com/help/date-appears-search-results/#h-managing-dates | |
*/ | |
add_action('wpseo_dc_'.'DC.date.issued', '__return_false'); // Premium versions 5.2 or older |
<template> | |
<div> | |
<input v-validate data-rules="required" :class="{'has-error': errors.has("textInput")}" id="textInput" name="textInput" type="text"> | |
<span class="error" v-show="errors.has("textInput")">{{ errors.first("textInput") }}</span> | |
</div> | |
</template> | |
<script> | |
import { find, propEq } from 'ramda' | |
import bus from './bus' |
<?php | |
class RetryTest extends TestCase | |
{ | |
public function setUp() | |
{ | |
parent::setUp(); | |
// abuse superglobal to keep track of state | |
$_GET['a'] = 0; | |
} |
add_action('post_submitbox_misc_actions', createCustomField); | |
add_action('save_post', saveCustomField); |
// Cache user inputs into HTML5 local storage. Restore them upon next page load. | |
// Usage: | |
// $('body').CacheInputs(); | |
// | |
// Will store stringified JSON in local storage, against the key you specify | |
// or 'cache-inputs' if you omit it. See settings below. | |
// | |
// Author: Martin Drapeau | |
// | |
// Greatly inspired from Johnathan Schnittger |
function retry(isDone, next) { | |
var current_trial = 0, max_retry = 50, interval = 10, is_timeout = false; | |
var id = window.setInterval( | |
function() { | |
if (isDone()) { | |
window.clearInterval(id); | |
next(is_timeout); | |
} | |
if (current_trial++ > max_retry) { | |
window.clearInterval(id); |
/** | |
* IE 5.5+, Firefox, Opera, Chrome, Safari XHR object | |
* | |
* @param string url | |
* @param object callback | |
* @param mixed data | |
* @param null x | |
*/ | |
function ajax(url, callback, data, x) { | |
try { |