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
# Path to the Oh-my-zsh install | |
export ZSH=$HOME/.oh-my-zsh | |
# Add all the required portions to the PATH | |
export PATH="/usr/local/opt/ruby/bin:$HOME/bin:$PATH"; | |
# Source NVM | |
source ~/.nvm/nvm.sh | |
# ZSH Configurations |
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
/** | |
* Populate a map with the values of an object with nested maps | |
* | |
* @param {Map} map - Map to populate | |
* @param {object} object - Object to use for the population | |
* @param {array} keys - Array of keys of the object | |
* | |
* @return {Map} Populated map | |
*/ | |
function populateMap (map, object, keys) { |
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
# Your init script | |
# | |
# Atom will evaluate this file each time a new window is opened. It is run | |
# after packages are loaded/activated and after the previous editor state | |
# has been restored. | |
# | |
# An example hack to log to the console when each text editor is saved. | |
# | |
# atom.workspace.observeTextEditors (editor) -> | |
# editor.onDidSave -> |
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
var flatten = arr => arr.reduce((p, c) => p.concat(Array.isArray(c) ? flatten(c) : c), []); | |
/** | |
* Credit goes to Benjamin Gruenbaum, from his comment on this article: http://www.2ality.com/2016/04/promise-trees.html | |
*/ |
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
@sentis/emails | |
├── index.js | |
└── src/ | |
├── App.js | |
├── elements/ | |
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
componentDidUpdate(prevProps) { | |
console.log('Rrow update diff:'); | |
const now = Object.entries(this.props); | |
const added = now.filter(([key, val]) => { | |
if (prevProps[key] === undefined) return true; | |
if (prevProps[key] !== val) { | |
console.log(`${key} | |
- ${JSON.stringify(val)} |
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
import React from 'react'; | |
const style = { | |
title: { | |
fontSize: '24px', | |
fontWeight: 'bold', | |
marginTop: '5px', | |
marginBottom: '10px', | |
}, |
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
import React from 'react'; | |
function Cell({ children }) { | |
return <td>{children}</td>; | |
} | |
function Row({ children }) { | |
return ( | |
<tr> | |
{React.Children.map(children, (el) => { |
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
- <h1 style={style.title}> | |
+ <h1 style={style.title} className="title-heading"> | |
{children} | |
</h1> |
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
import React from 'react'; | |
import ReactDOM from 'react-dom'; | |
+import './inlined.css'; |
OlderNewer