Skip to content

Instantly share code, notes, and snippets.

View ihpannu's full-sized avatar
🏠
Working from home

Harman Pannu ihpannu

🏠
Working from home
View GitHub Profile
@ihpannu
ihpannu / index.html
Created December 18, 2017 08:36
React Awesome Video Player
<main id="app"></main>
@ihpannu
ihpannu / index.pug
Created December 19, 2017 02:08
React Photo Carousel
#app
@ihpannu
ihpannu / css-grid-responsive-website.markdown
Created January 22, 2018 20:03
CSS GRID Responsive Website
@ihpannu
ihpannu / magic.css
Created May 10, 2018 23:45
CSS MAGIC
/* Responsive Circle */
/* make sure your padding top is the same as your width and make your height auto. */
.circle {
position: relative;
border-radius: 50%;
width: 100%;
height: auto;
padding-top: 100%;
background: white;
}
{"v":"5.3.4","fr":29.9700012207031,"ip":0,"op":150.000006109625,"w":1600,"h":1600,"nm":"Text Comp","ddd":0,"assets":[],"layers":[{"ddd":0,"ind":3,"ty":3,"nm":"Shape Layer 1","sr":1,"ks":{"o":{"a":0,"k":68,"ix":11},"r":{"a":0,"k":0,"ix":10},"p":{"a":0,"k":[576,786.5,0],"ix":2},"a":{"a":0,"k":[-223.59,-13.114,0],"ix":1},"s":{"a":1,"k":[{"i":{"x":[0.667,0.667,0.667],"y":[1,1,1]},"o":{"x":[0.167,0.167,0.167],"y":[0.167,0.167,0.761]},"n":["0p667_1_0p167_0p167","0p667_1_0p167_0p167","0p667_1_0p167_0p761"],"t":55,"s":[29,29,100],"e":[82,82,100]},{"i":{"x":[0.667,0.667,0.667],"y":[1,1,1]},"o":{"x":[0.167,0.167,0.167],"y":[0.167,0.167,0.489]},"n":["0p667_1_0p167_0p167","0p667_1_0p167_0p167","0p667_1_0p167_0p489"],"t":65,"s":[82,82,100],"e":[75,75,100]},{"i":{"x":[0.667,0.667,0.667],"y":[1,1,1]},"o":{"x":[0.167,0.167,0.167],"y":[0.167,0.167,5.803]},"n":["0p667_1_0p167_0p167","0p667_1_0p167_0p167","0p667_1_0p167_5p803"],"t":70,"s":[75,75,100],"e":[82,82,100]},{"i":{"x":[0.667,0.667,0.667],"y":[1,1,1]},"o":{"x":[0.167,0.
@ihpannu
ihpannu / asyncloops.js
Last active June 15, 2019 03:55 — forked from lukehoban/asyncloops.js
Async/await and parallel loops
// ES6 w/ Promises
// Note: From a React starter template - see https://t.co/wkStq8y3I5
function fetchData(routes, params) {
let data = {};
return Promise.all(routes
.filter(route => route.handler.fetchData)
.map(route => {
return route.handler.fetchData(params).then(resp => {
data[route.name] = resp;
@ihpannu
ihpannu / delete-all-tweets.py
Last active March 31, 2022 14:13
Python script to delete all tweets using Python version 3
import tweepy
import _thread
consumer_key = ''
consumer_secret = ''
access_key = ''
access_secret = ''
def deleteThread(api, objectId):