Skip to content

Instantly share code, notes, and snippets.

@pablobm
Created March 15, 2016 16:41
Show Gist options
  • Save pablobm/2e08b1cb308e75e7bd59 to your computer and use it in GitHub Desktop.
Save pablobm/2e08b1cb308e75e7bd59 to your computer and use it in GitHub Desktop.
Error substate with classic paths
<p>error.hbs</p>
import Ember from 'ember';
import config from './config/environment';
const Router = Ember.Router.extend({
location: 'none'
});
Router.map(function() {
this.route('root', {path: '/'});
});
export default Router;
import Ember from 'ember';
export default Ember.Route.extend({
model() {
return Ember.RSVP.reject({error: "KPOW!"});
},
});
<h1>templates/application.hbs</h1>
{{outlet}}
<p>templates/root.hbs</p>
{
"version": "0.6.4",
"EmberENV": {
"FEATURES": {}
},
"options": {
"enable-testing": false
},
"dependencies": {
"jquery": "https://cdnjs.cloudflare.com/ajax/libs/jquery/1.11.3/jquery.js",
"ember": "https://cdnjs.cloudflare.com/ajax/libs/ember.js/2.4.1/ember.debug.js",
"ember-data": "https://cdnjs.cloudflare.com/ajax/libs/ember-data.js/2.4.0/ember-data.js",
"ember-template-compiler": "https://cdnjs.cloudflare.com/ajax/libs/ember.js/2.4.1/ember-template-compiler.js"
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment