Skip to content

Instantly share code, notes, and snippets.

@phawk
Created October 25, 2012 13:25
Show Gist options
  • Save phawk/3952527 to your computer and use it in GitHub Desktop.
Save phawk/3952527 to your computer and use it in GitHub Desktop.
render: function() {
var html, $html;
html = new EJS({
url: app.config.locations.templates + 'dialogs/font-selection.ejs?' + cacheBeater
}).render();
$html = $(html);
// Render and instantiate the sub views within html
this.views["fontSearchActions"] = new this.fontSearchActions({
el: $html.find('.font-search-actions-container'),
allFontProviders: this.getAllFontProviders()
});
this.views["fontSearchResults"] = new this.fontSearchResults({
el: $html.find('.font-search-results-container')
});
// Add this view and subviews html to the dom in one go
this.$el.html($html);
return this;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment