Created
December 9, 2014 22:20
-
-
Save fbaiodias/fcf55731344ee2d1fe17 to your computer and use it in GitHub Desktop.
node-webkit youtube player
This file contains 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
<html> | |
<body> | |
<link rel="stylesheet" href="style.css"> | |
<script src="index.js"></script> | |
<iframe id="container"></iframe> | |
</body> | |
</html> |
This file contains 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 $ = require('jquery'); | |
var playlists = [ | |
'https://www.youtube.com/watch?v=hyG_x5eXbnM&list=UU3ifTl5zKiCAhHIBQYcaTeg', | |
// ... | |
] | |
$(document).ready(function() { | |
$('#container').attr('src', playlists[0]); | |
}); |
This file contains 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
{ | |
"name": "player", | |
"description": "", | |
"main": "index.html", | |
"dependencies": { | |
"jquery": "^2.1.1" | |
}, | |
"webkit": { | |
"plugin": true | |
} | |
} |
This file contains 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
body { | |
margin: 0; | |
padding: 0; | |
} | |
iframe { | |
width: 100%; | |
height: 100%; | |
border: 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment