 		return unless @_dom
 		child = @_dom.firstElementChild
 		while child
-			if child.nodeName == "TEMPLATE"
+			if child.nodeName is "TEMPLATE"
 				@regTemplate(child)
 			child = child.nextElementSibling
 		@_regDefaultTemplates()


	trimTemplate: (template) ->
		if template.nodeType
			if template.nodeName == "TEMPLATE"
				if not template.firstChild
					html = template.innerHTML
					if html

		while child
			next = child.nextSibling
			if child.nodeType is 3	# TEXT
				if $.trim(child.nodeValue) is ""
					dom.removeChild(child)
			child = next
		return
