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
| require_once( ABSPATH . 'wp-includes/class-oembed.php' ); | |
| $WP_oEmbed = new WP_oEmbed(); | |
| $data = $WP_oEmbed->get_data( $video_url ); | |
| $thumbnail_url = $data->thumbnail_url; | |
| // to be stored in data attribute until needed | |
| $lightbox_markup = htmlentities( $WP_oEmbed->data2html( $data, $video_url), ENT_QUOTES ); |
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
| { | |
| "empty-lines-between-children-rules": 0, | |
| "empty-lines-between-media-rules": 0, | |
| "sort-order": [ | |
| [ "$variable" ], | |
| [ | |
| "position", | |
| "top", | |
| "right", | |
| "bottom", |
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
| { | |
| "rules": { | |
| "at-rule-semicolon-newline-after": "always", | |
| "block-closing-brace-newline-after": "always", | |
| "block-closing-brace-newline-before": "always", | |
| "block-opening-brace-newline-after": "always", | |
| "block-opening-brace-space-before": "always", | |
| "color-hex-case": "lower", | |
| "declaration-colon-space-after": "always", | |
| "declaration-colon-space-before": "never", |
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
| { | |
| "empty-lines-between-children-rules": 0, | |
| "empty-lines-between-media-rules": 0, | |
| "sort-order": [ | |
| [ "$variable" ], | |
| [ | |
| "position", | |
| "top", | |
| "right", | |
| "bottom", |
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
| /*eslint-disable no-unused-vars*/ | |
| import React from 'react'; | |
| /*eslint-enable no-unused-vars*/ | |
| import ReactDOM from 'react-dom'; | |
| const connectCursor = (bindings) => { | |
| return (Component) => { | |
| return (props) => Component(bindings(props)); | |
| }; | |
| } |
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 browserSync = require('browser-sync'); | |
| module.exports = function (grunt) { | |
| grunt.initConfig({ | |
| watch: { | |
| options: { | |
| spawn: false | |
| }, | |
| compiled: { | |
| files: ['app/build/bundle.js'], |
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
| module.exports = function(grunt) { | |
| grunt.initConfig({ | |
| pkg: grunt.file.readJSON('package.json'), | |
| watch: { | |
| default: { | |
| files: ['**/*.*', '!_site/**.*'], | |
| tasks: ['jekyll'], |
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 element = document.getElementById('foo'); | |
| var nodes = [element]; | |
| var value = ''; | |
| var counter = 1; | |
| while (nodes.length > 0) { | |
| element = nodes.shift(); | |
| Array.prototype.map.call(element.children, function(node){nodes.push(node);}); | |
| value += ['\n/*',counter++,'*/\n'].join(''); |