diff --git a/cms/static/js/views/components/add_xblock_button.js b/cms/static/js/views/components/add_xblock_button.js index aba7bd91b9..e0c4cc522d 100644 --- a/cms/static/js/views/components/add_xblock_button.js +++ b/cms/static/js/views/components/add_xblock_button.js @@ -1,16 +1,17 @@ -define(['js/views/baseview'], - function(BaseView) { +define(['js/views/baseview', 'edx-ui-toolkit/js/utils/html-utils'], + function(BaseView, HtmlUtils) { + 'use strict'; return BaseView.extend({ tagName: 'li', initialize: function() { + var attributes = { + type: this.model.type, + templates: this.model.templates, + display_name: this.model.display_name + }; BaseView.prototype.initialize.call(this); this.template = this.loadTemplate('add-xblock-component-button'); - this.$el.html( - this.template({ - type: this.model.type, - templates: this.model.templates, - display_name: this.model.display_name - }) + this.$el.html(HtmlUtils.HTML(this.template(attributes)).toString() ); } });