Skip to content

Instantly share code, notes, and snippets.

// player is the MTVNPlayer.Player object created by the embed api
player.on("stateChange:paused", function(event){
// we don't want to do this for flash
if(MTVNPlayer.isHTML5Player){
if(!event.target.element.webkitDisplayingFullscreen){
alert("show your poster screen, we're not in full screen");
}
}
});
{
"package":
{"video":
{"item":
[ // 2 elements in Array
{
"vmap":{...},
"transcript":{...},
"beacon":{...}
},
<!DOCTYPE html>
<html>
<head>
<style>
.MTVNPlayer {
width: "100%";
height: "100%";
}
</style>
<script type="text/javascript">
{
// --------------------------------------------------------------------
// JSHint Configuration, Strict Edition
// --------------------------------------------------------------------
//
// This is a options template for [JSHint][1], using [JSHint example][2]
// and [Ory Band's example][3] as basis and setting config values to
// be most strict:
//
// * set all enforcing options to true
{
"package": {
"version": "1.7.4",
"video": {
"item": [{
"origination_date": "07-25-2014 11:07:40",
"vmap": {
"vmap:VMAP": {
"@version": "1.0",
"@xmlns:uo": "uo",
/* global _ */
var Thumbnails = {
// util to get the number of 0s
getTimeString: function(chars) {
var s = "";
_.times(4 - chars, function() {
s += "0";
});
return s;
},
@giannif
giannif / thumbnail-finder2.js
Created November 21, 2014 18:12
return the image object
/* global _ */
var Thumbnails = {
// util to get the number of 0s
getTimeString: function(chars) {
var s = "";
_.times(4 - chars, function() {
s += "0";
});
return s;
},
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>Webpack Bundle Analyzer</title>
<!-- viewer.js -->

To use private modules in your project

Generate an auth token for your .npmrc

Use npm login

  • remove your existing ~/.npmrc, since it won't override
  • npm login
  • copy to project directory
  • never logout npm logout clears your token everywhere
@giannif
giannif / History|-1028b3f9|entries.json
Last active August 10, 2022 15:54
Visual Studio Code Settings Sync Gist
{"version":1,"resource":"file:///Users/giannif/Code/giphy/web-app/app/nextjs/util/meta/twitter-meta.tsx","entries":[{"id":"OpUK.tsx","source":"Workspace Edit","timestamp":1658202845273},{"id":"L5qA.tsx","timestamp":1658203898620},{"id":"nLt3.tsx","timestamp":1658203927166},{"id":"0kYs.tsx","source":"Workspace Edit","timestamp":1660088467972},{"id":"mLrG.tsx","source":"Workspace Edit","timestamp":1660091765586}]}