Skip to content

Instantly share code, notes, and snippets.

View abhijit-hota's full-sized avatar
🦕

Abhijit Hota abhijit-hota

🦕
View GitHub Profile
@abhijit-hota
abhijit-hota / Try-to-check-it..markdown
Created November 22, 2014 13:51
Try to check it.
@abhijit-hota
abhijit-hota / Reflection-Typography.markdown
Last active August 29, 2015 14:13
Reflection Typography
@abhijit-hota
abhijit-hota / Scroll-down-that-hole..markdown
Created February 12, 2015 04:53
Scroll down that hole.
@abhijit-hota
abhijit-hota / Study tool #1 - Hydrocarbons.markdown
Created October 27, 2015 15:30
Study tool #1 - Hydrocarbons

Study tool #1 - Hydrocarbons

I'll make more like this. I didn't make this pen responsive because I'm pretty bad at it. The main concept was to use the 'alkane', 'alkene' and 'alkyne' formula. Hope you alll like it! Please heart

I'll be thankful if anyone would help me making it responsive! :)

A Pen by Abhijit Hota on CodePen.

License.

@abhijit-hota
abhijit-hota / youtube-playlist-total-time.js
Last active July 15, 2021 13:18
Output total time of a playlist
/*
Note: This works for URLs like the following:
https://www.youtube.com/playlist?list=PLDV1Zeh2NRsAsbafOroUBnNV8fhZa7P4u
https://www.youtube.com/watch?v=oQQO_n57SB0&list=PLDV1Zeh2NRsAsbafOroUBnNV8fhZa7P4u&index=6
*/
const extra = window.location.pathname === "/watch" ? "panel-" : "";
const tag = `ytd-playlist-${extra}video-renderer`;
const playlistPanel = Array.from(document.getElementsByTagName(tag));
@abhijit-hota
abhijit-hota / test-apis-by-generator-function.js
Last active November 10, 2020 03:49
Using generator functions in JavaScript for error handling
// Use case (?):
// Suppose you have an array of API keys from a service. We all know why you'd have multiple API keys of a single service.
// For some reason, you know that all of them are not gonna work at all times. This is the exact scenario replicated here.
// Dummy array with, let's say, dummy API keys
const api_key_array = [
"vikiohcucbigpinekjodumehdarhagbevrosolhivuvasodumsumvivahpiupaba",
"leluralcotaimgamenfukhajuzkusamubiezilezigiczaduspiwovefniuzaleh",
"wuvoneuvtucesilluleftovarkohlucukjarineetizokujunetejzaanviromdo",
"foccuseucopozecepiogaejegafpellozumoderajewtotlomkigmecaluhindig",
{
"10": "Bad or missing API token",
"100": "Maintenance",
"300": "Invalid email request",
"400": "Sender Signature not found",
"401": "Sender signature not confirmed",
"402": "Invalid JSON",
"403": "Incompatible JSON",
"405": "Not allowed to send",
"406": "Inactive recipient",

Keybase proof

I hereby claim:

  • I am abhijit-hota on github.
  • I am kretaceous (https://keybase.io/kretaceous) on keybase.
  • I have a public key ASBac46AhTrj1VqziHIi9jN5F0Bgtd6ru9023MyFfLdVngo

To claim this, I am signing this object: