How to show a block of html or div to the bottom of a web page
To download this code from git: See: Gyanblog Github
March 04, 2018
This library is ES6, promise compatible.
Or, in your package.json file, include: youtube-api-es6 by running commmand:
npm install youtube-api-es6
const youtubeService = require('youtube-api-es6').youtubeService;
const youtubeConfig = {
key: 'Your key'
};
return youtubeService.init(youtubeConfig)
.then(function() {
return youtubeService.getVideoDetail('a7hGVtz8syM');
})
.then(function(res) {
console.log(JSON.stringify(res, null, 3));
});
const youtubeService = require('youtube-api-es6').youtubeService;
const youtubeConfig = {
key: 'your key'
};
youtubeService.init(youtubeConfig);
// playlistId: 'xxx',
type: 'video'
};
<h3>getVideoDetail(videoId, detailOptions)</h3>
Get video details. Second parameter is optional: detailOptions, and by default it returns details for levels: snippet,contentDetails,topicDetails,statistics.
You can also pass which level of details you want in this parameter. Each level should be passed comma separated.
Example:
```js
getVideoDetail(1234, 'snippet,statistics');
Use api:
getVideoDetail(videoId, 'snippet')
const youtubeService = require('youtube-api-es6').youtubeService;
const youtubeConfig = {
key: 'Your key'
};
return youtubeService.init(youtubeConfig)
.then(function() {
return youtubeService.getVideoDetail('a7hGVtz8syM', 'snippet');
})
.then(function(res) {
console.log(JSON.stringify(res, null, 3));
});
To download this code from git: See: Gyanblog Github
hook_cron() suggests to put tasks that executes in shorter time or non-resource…
Introduction to problem So, on my mac, I’ev set timezone to my local city i.e…
I have a Java project and dependencies are being managed through maven. I have…
Listing down the commonly used Elastic Search queries. You can get search…
Introduction In our previous post How to configure Grafana on docker, we saw how…
In this post, we will see some of the frequently used concepts/vocabulary in…
System design interview is pretty common these days, specially if you are having…
Introduction You are given an array of integers with size N, and a number K…
Graph Topological Sorting This is a well known problem in graph world…
Problem Statement Given a Binary tree, print out nodes in level order traversal…
Problem Statement Given an array nums of n integers and an integer target, are…