I get these error messages when loading a page:
Assertion failed: The value that
Here is my template code:
<script type="text/x-handlebars" data-template-name="snippets/index"> {{#each}} {{title}} {{/each}} </script>
My Snippet model is pretty simple:
TSLibrary.Snippet = DS.Model.extend({ title: DS.attr('string') }); TSLibrary.Snippet.FIXTURES = [{id: 1, title: 'Learn Ember.js'}];
My application and my router:
window.TSLibrary = Ember.Application.create(); TSLibrary.ApplicationAdapter = DS.FixtureAdapter.extend(); // --- TSLibrary.Router.map(function () { this.resource('snippets', { path: '/' }, function () { }); }); TSLibrary.SnippetsRoute = Ember.Route.extend({ model: function () { // My guess is that this does not return the expected array // // This logs 'Class {toString: function, constructor: function, reason: null, isPending: undefined, isSettled: undefined…}' console.log(this.store.find('snippet')); return this.store.find('snippet'); } });
Therefore, I assume that this.store.find('snippet')
does not return the correct data. I also installed the Ember debug extension in Chrome, and it shows me all the data I need in my model.
Amber Version: 1.0.0
Ember Data version: v1.0.0-beta.1-140-ga51f29c a51f29c (2013-09-07 16:34:55 -0700)
Version for pens: 1.0.0
JQuery Version: 1.10.2
source share