Created
November 8, 2013 18:47
-
-
Save mbejda/7375641 to your computer and use it in GitHub Desktop.
This file contains 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> | |
<meta charset=utf-8 /> | |
<title>JS Bin</title> | |
<script src="http://code.jquery.com/jquery-2.0.2.js"></script> | |
<script src="http://builds.emberjs.com/handlebars-1.0.0.js"></script> | |
<script src="http://builds.emberjs.com/ember-latest.js"></script> | |
</head> | |
<body> | |
<script type="text/x-handlebars" id="application"> | |
<p>index!</p> | |
<p>{{#link-to 'page-1'}}Page 1{{/link-to}}</p> | |
<p>{{#link-to 'page-2'}}Page 2{{/link-to}}</p> | |
{{outlet}} | |
</script> | |
<script type="text/x-handlebars" data-template-name='index'> | |
hello world! Template | |
</script> | |
<script type="text/x-handlebars" data-template-name='page-1'> | |
Page 1 | |
</script> | |
<script type="text/x-handlebars" data-template-name='page-2'> | |
Page 2 | |
</script> | |
</body> | |
<script> | |
window.App = Ember.Application.create(); | |
App.Router.map(function() { | |
this.resource('page-1') | |
this.resource('page-2') | |
}); | |
App.IndexRoute = Ember.Route.extend({ | |
}); | |
App.initialize(); | |
</script> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment