Skip to content

Instantly share code, notes, and snippets.

View hedgerworkco's full-sized avatar

Harry Hedger hedgerworkco

View GitHub Profile
<snippet>
<content><![CDATA[
import ${1:cx} from '${2:classnames}';
]]></content>
<tabTrigger>cx</tabTrigger>
<scope>source.js</scope>
<description>React: import classnames package;</description>
</snippet>
["^ ","posts",["~#iM",["postsById",["^1",["Stop-Trying-to-Catch-Me",["^ ","date",20150407,"shorturl","Stop-Trying-to-Catch-Me","title","Stop Trying to Catch Me","published",true,"abstract","I'm probably going to regret this, but this post is about promises. There are a few details that I'd like to spell out so I can point people to this post instead of repeating myself. Here are a few reasons why I don't like promises.","content","I'm probably going to regret this, but this post is about promises. There are a few details that I'd like to spell out so I can point people to this post instead of repeating myself. This is not a hyperbolic post like [Radical Statements about the Mobile Web](http://jlongster.com/Radical-Statements-about-the-Mobile-Web), which I sort of regret posting. In that post I was just yelling from a mountaintop, which isn't very helpful.\n\nI humbly submit these points as reasons why I don't like promises, with full realization that the ship has sailed and nothing is going to change.\n\nFirs
export function winGame() {
return dispatch => {
dispatch(stopClock());
return {
type: 'WIN_GAME',
payload: {...}
};
}
};
.menu {
opacity: 0.0;
transform: translate3d(-100%, 0, 0);
transition: opacity 2s ease transform 2s ease;
}
.menu.is-open {
opacity: 1.0;
transform: translate3d(0, 0, 0);
transition: opacity 2s ease transform 2s ease;

#howto modal

Under /app/scripts/apps/internet.jsx:

const modalProps = {
  show: this.state.modalPayload.modalOpen,
  onHide: this.closeModal,
  container: document.body,
  dialogClassName: 'modal-fullscreen',

'aria-labelledby': 'contained-modal-title'

module: {
loaders: [{
test: /\.jsx?$/,
loader: 'babel',
exclude: [path.join(root, 'node_modules'), path.join(context, 'node_modules')]
},
{
test: /\.css$/,
loader: ExtractTextPlugin.extract('style-loader', 'css-loader')
}]
import { Modal, ModalHeader, ModalFooter } from '../../modal';
export { default as Modal } from './modal';
export { default as ModalBody } from './modal-body';
export { default as ModalFooter } from './modal-footer';
export { default as ModalHeader } from './modal-header';
export { default as ModalMarkup } from './modal-markup';
export { default as ModalTitle } from './modal-title';
export { default as Portal } from './portal';
var Parent = React.createClass({
onInputChange(e) {
this.setState({
input: e.target.value
});
},
filterCities(cities, input) {
return cities.filter(city => {
let { show, ...props } = this.props;