File tree Expand file tree Collapse file tree 1 file changed +12
-11
lines changed
Expand file tree Collapse file tree 1 file changed +12
-11
lines changed Original file line number Diff line number Diff line change 1818< body >
1919 < div id ="contents ">
2020
21+ 출처:< a href ="https://gist.github.com/ihoneymon/652be052a0727ad59601 "> https://gist.github.com/ihoneymon/652be052a0727ad59601</ a >
2122 < div id ="markdown_view ">
2223 </ div >
2324
2425 < script >
2526
2627 function renderMarkdwon ( markdown_view_id , markdown_url ) {
27- var xmlhttp = new XMLHttpRequest ( ) ;
28- xmlhttp . onreadystatechange =
29- function ( ) {
30- if ( this . readyState == 4 && this . status == 200 ) {
31- const html = marked . parse ( this . responseText ) ;
32- document . getElementById ( markdown_view_id ) . innerHTML = html ;
33- }
34- } ;
35-
36- xmlhttp . open ( "GET" , markdown_url , true ) ;
37- xmlhttp . send ( ) ;
28+ var xmlhttp = new XMLHttpRequest ( ) ;
29+ xmlhttp . onreadystatechange =
30+ function ( ) {
31+ if ( this . readyState == 4 && this . status == 200 ) {
32+ const html = marked . parse ( this . responseText ) ;
33+ document . getElementById ( markdown_view_id ) . innerHTML = html ;
34+ }
35+ } ;
36+
37+ xmlhttp . open ( "GET" , markdown_url , true ) ;
38+ xmlhttp . send ( ) ;
3839 }
3940
4041 renderMarkdwon ( "markdown_view" , "./page.md" ) ;
You can’t perform that action at this time.
0 commit comments