This file contains 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
const asyncHandler = | |
async (endpoint, options) => { | |
const rawData = await fetch(endpoint, {...options}); | |
return await rawData.json(); | |
}; | |
const data = asyncHandler('/the_endpoint'); | |
data.then(result => console.log(result)); |
This file contains 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
let t0 = performance.now(); | |
let t1 = performance.now(); | |
console.log("perf -> " + (t1 - t0) + " ms."); |
This file contains 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
cd ~/Library/Application\ Support/Google/Chrome/Default/User\ StyleSheets | |
echo 'html { -webkit-animation: adjustHue 20s infinite !important; } @-webkit-keyframes adjustHue { 50% { -webkit-filter: hue-rotate(360deg); }}' >> Custom.css |
This file contains 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
.ir { | |
border: 0; | |
font: 0/0 a; | |
text-shadow: none; | |
color: transparent; | |
background-color: transparent; | |
} |