Last active
September 25, 2020 22:53
-
-
Save jportella93/18bcc825710513ef7243e42c9941e0a9 to your computer and use it in GitHub Desktop.
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
git branch | egrep -v 'master|feat/something-neat' | xargs git branch -D |
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
// Create a layout component, that render children on slots. | |
const SplitPane = ({ leftComponent, rightComponent }) => ( | |
<div className="SplitPane"> | |
<div className="SplitPane-left">{leftComponent}</div> | |
<div className="SplitPane-right">{rightComponent}</div> | |
</div> | |
) | |
const App = () => <SplitPane left={<Contacts />} right={<Chat />} /> |
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 SplitPane = ({ leftComponent, rightComponent }) => ( | |
<div className="SplitPane"> | |
<div className="SplitPane-left">{leftComponent}</div> | |
<div className="SplitPane-right">{rightComponent}</div> | |
</div> | |
) | |
SplitPane.propTypes = { | |
leftComponent: PropTypes.oneOfType([PropTypes.node, PropTypes.element]), | |
rightComponent: PropTypes.oneOfType([PropTypes.node, PropTypes.element]), | |
} |
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
// Anything that can be rendered: numbers, strings, elements or an array | |
// (or fragment) containing these types. | |
optionalNode: PropTypes.node, | |
// A React element (ie. <MyComponent />). | |
optionalElement: PropTypes.element, |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment