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
/* | |
Google Drive API: | |
Demonstration to: | |
1. upload | |
2. delete | |
3. create public URL of a file. | |
required npm package: googleapis | |
*/ | |
const { google } = require('googleapis'); |
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
Number.prototype.padDigit = function () { | |
return (this < 10) ? '0' + this : this; | |
} | |
var time1 = "00:00"; | |
var secs = 0; | |
var mins = 0; | |
var hrs = 0; | |
$('.ytd-thumbnail-overlay-time-status-renderer').each(function(){ |
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
//@ts-check | |
console.time('Elapsed time'); | |
const playlistVideos = document.querySelector( | |
"#contents > ytd-playlist-video-list-renderer > #contents" | |
); | |
const spanTime = document.querySelectorAll( | |
"#overlays > ytd-thumbnail-overlay-time-status-renderer > span" | |
); | |
let playlistTime = 0; | |
for (let i = 0; i < playlistVideos.childElementCount; i++) { |
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
body { | |
font-family: tahoma; | |
color:#282828; | |
margin: 0px; | |
} | |
.nav-bar { | |
background: linear-gradient(-90deg, #84CF6A, #16C0B0); | |
height: 60px; | |
margin-bottom: 15px; |
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
// Colors reference | |
// You can use the following as so: | |
// console.log(colorCode, data); | |
// console.log(`${colorCode}some colorful text string${resetCode} rest of string in normal color`); | |
// | |
// ... and so on. | |
export const reset = "\x1b[0m" | |
export const bright = "\x1b[1m" | |
export const dim = "\x1b[2m" |