Skip to content

Instantly share code, notes, and snippets.

@mollerhoj
Created August 26, 2015 18:43
Show Gist options
  • Save mollerhoj/4a4b416e66fe20e4225c to your computer and use it in GitHub Desktop.
Save mollerhoj/4a4b416e66fe20e4225c to your computer and use it in GitHub Desktop.
adapter error message
import Ember from 'ember';
export default Ember.Controller.extend({
appName:'Ember Twiddle'
});
import DS from 'ember-data';
export default DS.Model.extend({
title: DS.attr('string')
});
import Ember from 'ember';
var App = window.App = Ember.Application.extend();
App.ApplicationAdapter = DS.RESTAdapter.extend({
host: 'https://api.gomore.com'
});
export default Ember.Route.extend({
model() {
return {
data: this.store.findAll('book')
};
}
});
<h1>Welcome to {{appName}}</h1>
<br>
<br>
{{#each books as |book|}}
{{book}}
{{/each}}
<br>
<br>
{
"version": "0.4.8",
"dependencies": {
"jquery": "https://cdnjs.cloudflare.com/ajax/libs/jquery/1.11.3/jquery.js",
"ember": "https://cdnjs.cloudflare.com/ajax/libs/ember.js/1.13.8/ember.js",
"ember-data": "https://cdnjs.cloudflare.com/ajax/libs/ember-data.js/1.13.9/ember-data.js",
"ember-template-compiler": "https://cdnjs.cloudflare.com/ajax/libs/ember.js/1.13.8/ember-template-compiler.js"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment