Skip to content

Instantly share code, notes, and snippets.

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

Hisa hisapy

🏠
Working from home
View GitHub Profile
@hisapy
hisapy / imperative_vs_functional.js
Last active October 24, 2018 21:07
"Imperative" vs Functional Javascript example
/*
Given props routeIndices such as [0, 2, 2, 4] and routes such as [RouteObj, RouteObj] passed to a React component,
use the routeIndices to traverse down the routes tree, via RouteObj children, to get the RouteObj title attribute.
For example, a <Route title="Home" /> from Found.
*/
getTitleFromRouteImperative() {
const { routeIndices, routes } = this.props;
@hisapy
hisapy / JobSearchGoogleSheet.js
Last active December 11, 2019 21:06
JavaScript for Google Sheet to track job Search
/**
* Google Sheet:
* https://docs.google.com/spreadsheets/d/1rkPwzZIE60Tjdk-Rq18tewy48vdpWk1dSD3wr4wp81w/copy
*
* For more info see:
* https://medium.com/@hisa_py/google-sheet-to-track-job-search-68c88c699d33
*/
// globals
var STATUS_COLUMN = 12;