This file contains hidden or 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
<ul class="flex-container"> | |
<li class="flex-item item1">1</li> | |
<li class="flex-item item2">2</li> | |
<li class="flex-item item3">3</li> | |
<li class="flex-item item4">4</li> | |
<li class="flex-item item5">5</li> | |
<li class="flex-item item6">6</li> | |
</ul> |
This file contains hidden or 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
a{ | |
cursor: pointer; | |
} | |
a:hover { | |
text-decoration: none; | |
} | |
a.active { | |
color: #e64d33; | |
font-size: 16px |
This file contains hidden or 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
<!DOCTYPE html> | |
<html> | |
<head> | |
<script src="http://code.jquery.com/jquery.js"></script> | |
<script src="//cdnjs.cloudflare.com/ajax/libs/handlebars.js/1.0.0/handlebars.js"></script> | |
<script src="http://builds.emberjs.com/ember-latest.js"></script> | |
<meta charset=utf-8 /> | |
<title>JS Bin</title> | |
</head> | |
<body> |
This file contains hidden or 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
.bar { | |
fill: steelblue; | |
} | |
a:hover { | |
text-decoration: none; | |
} | |
a.active { | |
color: maroon; | |
font-size: 18px; | |
} |
This file contains hidden or 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 mergeItem = function(item){ | |
if(Em.typeOf(item) === 'object') { | |
item = merge({}, item); | |
} else if(Em.typeOf(item) === 'array') { | |
item = mergeArray(item); | |
} | |
return item; | |
}; | |
var mergeArray = function(arr) { |
This file contains hidden or 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
function ajax (url, options) { | |
return new Ember.RSVP.Promise(function (resolve, reject) { | |
options = options || {}; | |
options.url = url; | |
options.success = function (data) { | |
Ember.run(null, resolve, data); | |
}; | |
options.error = function (jqxhr, status, something) { |
This file contains hidden or 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
/* Put your CSS here */ | |
html, body { | |
margin: 20px; | |
} |
This file contains hidden or 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 {SomeModel} from 'some/path/to/somemodel'; | |
moduleFor("controller:somecontroller", "My Query in subject", { | |
subject: function(options, factory) { | |
return factory.create({ | |
content: SomeModel.create() | |
}); | |
} | |
}); |
This file contains hidden or 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 get = Em.get; | |
App.Router.map(function() { | |
this.route('something'); | |
this.route('somethingelse', {path: '/somethingelse/:foo_id/:bar_id/:baz_id'}); | |
}); | |
App.SomethingelseRoute = Em.Route.extend({ | |
model: function(params) { | |
//fetch the model |
This file contains hidden or 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
// Extend Ember.Route to add support for sensible | |
// document.title integration. | |
Ember.Route.reopen({ | |
// `titleToken` can either be a static string or a function | |
// that accepts a model object and returns a string (or array | |
// of strings if there are multiple tokens). | |
titleToken: null, |
OlderNewer