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 Ember from 'ember'; | |
import DS from 'ember-data'; | |
export default DS.RESTAdapter.extend({ | |
host: 'https://api.github.com', | |
namespace: 'search/issues', | |
query(store, b, query) { | |
const url = `${this.get('host')}/${this.get('namespace')}`; | |
let q = 'repo:FortAwesome/Font-Awesome'; | |
const _query = {...query}; |
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 DS from 'ember-data'; | |
export default DS.RESTAdapter.extend({ | |
host: 'https://api.github.com', | |
namespace: 'repos/emberjs/ember.js', | |
query(store, b, query) { | |
store.serializerFor('issue').set('pageSize', query.per_page); | |
const url = `${this.get('host')}/${this.get('namespace')}/issues`; | |
return this.ajax(url, 'GET', {data: query}); | |
}, |
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 DS from 'ember-data'; | |
export default DS.JSONAPIAdapter.extend({ | |
host: 'https://www.googleapis.com', | |
namespace: 'books/v1/volumes' | |
}); |
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 Ember from 'ember'; | |
export default Ember.Component.extend({ | |
actions: { | |
collapseRow(index, record) { | |
this.get('collapseRow')(index, record); | |
}, | |
expandRow(index, record) { | |
this.get('expandRow')(index, record); | |
} |
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 Ember from 'ember'; | |
export default Ember.Controller.extend({ | |
appName: 'Ember Twiddle', | |
data: [ | |
{id: '1', firstName: 'Jim', lastName: 'Raynor'}, | |
{id: '2', firstName: 'Sarah', lastName: 'Kerrigan'}, | |
{id: '3', firstName: 'Rory', lastName: 'Swann'}, | |
{id: '4', firstName: 'Tychus', lastName: 'Findlay'}, | |
{id: '5', firstName: 'Nova', lastName: 'Tera'}, |
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 Ember from 'ember'; | |
export default Ember.Component.extend({ | |
actions: { | |
collapseAllRows() { | |
Ember.get(this, 'collapseAllRows')(); | |
}, | |
expandAllRows() { | |
Ember.get(this, 'expandAllRows')(); | |
} |
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
#!/bin/bash | |
me=$(basename $0) | |
USAGE="Usage:\t$me ssh-key-file ip1 ip2 .. ipN\n\n\t$me ssh-key-file file_with_hosts.txt\n\n\t\tfile_with_hosts:\n\t\t\thostname1 ip1\n\t\t\thostname2 ip2\n\t\t\t...\n\t\t\thostnameN ipN\n\n\t\tfile_with_hosts:\n\t\t\tip1\n\t\t\tip2\n\t\t\t...\n\t\t\tipN"; | |
hash jq 2>/dev/null || { echo >&2 "jq should be installed ('apt-get install jq')"; exit 1; } | |
# no parameters are provided | |
if [ -z "$1" ] |
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 Ember from 'ember'; | |
export default Ember.Controller.extend({ | |
appName: 'Ember Twiddle' | |
}); |
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 Ember from 'ember'; | |
import Resolver from './resolver'; | |
import loadInitializers from 'ember-load-initializers'; | |
import config from './config/environment'; | |
let App; | |
Ember.MODEL_FACTORY_INJECTIONS = true; | |
App = Ember.Application.extend({ |