Skip to content

Instantly share code, notes, and snippets.

@bensmithett
bensmithett / SassMeister-input.scss
Created March 27, 2014 05:50
Generated by SassMeister.com.
// ----
// Sass (v3.3.4)
// Compass (v1.0.0.alpha.18)
// ----
.parent-class {
&.dropdown-toggle {
color: red;
}
}
@bensmithett
bensmithett / SassMeister-input-HTML.html
Created March 27, 2014 06:01
Generated by SassMeister.com.
<div class="parent-class dropdown-toggle">Hi</div>
<div class="dropdown-toggle parent-class">Hi</div>
var views = {
foo: function($el, el, props) {
console.log(props);
},
bar: function($el, el, props) {
console.log(props);
}
};
viewloader.execute(views);
@bensmithett
bensmithett / todo.md
Created April 13, 2014 08:04
Stuff I want to try out after CSSConf, JSConf & Decompress
@bensmithett
bensmithett / SassMeister-input.sass
Created July 21, 2014 23:17
Generated by SassMeister.com.
// ----
// Sass (v3.2.19)
// Compass (v0.12.6)
// ----
.text-label-beta
//-------------------------------
// Size
//-------------------------------
&.-size-small
@bensmithett
bensmithett / MyComponent.js
Created August 7, 2014 13:19
Trying out react-style
/**
* @jsx React.DOM
*/
"use strict";
var React = require("react/addons");
var ReactStyle = require("react-style");
var MyComponent = React.createClass({
@bensmithett
bensmithett / SassMeister-input-HTML.html
Created August 24, 2014 01:22
Generated by SassMeister.com.
<a am-Button am-type="downcase">Foo!</a>
@bensmithett
bensmithett / SassMeister-input.sass
Created December 11, 2014 03:12
Generated by SassMeister.com.
// ----
// Sass (v3.4.7)
// Compass (v1.0.1)
// ----
.foo
color: red
@media screen and (min-width: 1024px)
color: blue
@bensmithett
bensmithett / SassMeister-input-HTML.html
Last active August 29, 2015 14:11
Generated by SassMeister.com.
<div class="grid">
<div class="grid__col"><div class="content">foo</div></div>
<div class="grid__col"><div class="content">foo</div></div>
<div class="grid__col"><div class="content">foo</div></div>
</div>
<div class="grid -gutters">
<div class="grid__col"><div class="content">foo</div></div>
<div class="grid__col"><div class="content">foo</div></div>
<div class="grid__col"><div class="content">foo</div></div>
@bensmithett
bensmithett / notes.md
Created February 11, 2015 22:41
@orodio's melbjs flux talk

Make server calls from action creator, but don't dispatch an action. When the promise resolves, call another function that actually dispatches an action.

dispy is cool, abstracts a bit of boilerplate

  • Store.subscribe/unsubscribe
  • Stores register individual callbacks for each action rather than a big switch.
  • Simple mixin to get initial state & update it with one function (in controller view) mixins: [subscribe(state, store)]

orodio/melbjs-feb-2015