Skip to content

Instantly share code, notes, and snippets.

@xero
Created August 8, 2013 14:03
Show Gist options
  • Select an option

  • Save xero/6184844 to your computer and use it in GitHub Desktop.

Select an option

Save xero/6184844 to your computer and use it in GitHub Desktop.

Revisions

  1. xero harrison created this gist Aug 8, 2013.
    9 changes: 9 additions & 0 deletions ajaxBackboneHandlebars.js
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,9 @@
    $.ajax({
    url: 'ui/tpl/login.handlebars',
    context: this,
    cache: true,
    success: function(data) {
    var tpl = Handlebars.compile(data);
    this.$el.html(tpl(this.model.toJSON()));
    }
    });