Skip to content

Instantly share code, notes, and snippets.

@selvagsz
Last active December 21, 2015 06:39
Show Gist options
  • Save selvagsz/6266081 to your computer and use it in GitHub Desktop.
Save selvagsz/6266081 to your computer and use it in GitHub Desktop.
<!DOCTYPE html>
<html>
<head>
<script src="http://code.jquery.com/jquery.js"></script>
<script src="//cdnjs.cloudflare.com/ajax/libs/handlebars.js/1.0.0/handlebars.js"></script>
<script src="http://builds.emberjs.com/ember-latest.js"></script>
<meta charset=utf-8 />
<title>JS Bin</title>
</head>
<body>
<script type="text/x-handlebars" data-template-name='application'>
{{view Em.TextField value="1" tabindexBinding="one"}}
{{view Em.TextField value="2" tabindexBinding="two"}}
{{view Em.TextField value="3" tabindexBinding="three"}}
{{view Em.TextField value="4"}}
<button {{action changeTabOrder }}>Change tab order</button>
</script>
</body>
</html>
var App = window.App = Em.Application.create();
App.ApplicationController = Em.ObjectController.extend({
one: 1,
two: 2,
three: 3,
changeTabOrder: function () {
this.set('two', 4);
this.set('three', 2);
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment