Преглед на файлове

fix markdown typo, update comment #1780

Hakim El Hattab преди 8 години
родител
ревизия
02a6b0515e
променени са 1 файла, в които са добавени 3 реда и са изтрити 2 реда
  1. 3 2
      plugin/markdown/markdown.js

+ 3 - 2
plugin/markdown/markdown.js

@@ -30,8 +30,9 @@
 	 * element. Normalizes leading tabs/whitespace.
 	 */
 	function getMarkdownFromSlide( section ) {
-		// support <textarea data-template> `some code` </textarea>
-		var template = section.querySelector( '[data-tempate]' ) || section.querySelector( 'script' );
+
+		// look for a <script> or <textarea data-template> wrapper
+		var template = section.querySelector( '[data-template]' ) || section.querySelector( 'script' );
 
 		// strip leading whitespace so it isn't evaluated as code
 		var text = ( template || section ).textContent;