Why so secretive about the API? #2527
-
This is essentially one function. Yet, I can't find out what happens when I feed invalid markdown to |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 3 replies
-
Okay I found the live editor. Looks like it spits the raw string back out. |
Beta Was this translation helpful? Give feedback.
-
Any string input to Marked.js is technically "valid". No matter what string you feed into |
Beta Was this translation helpful? Give feedback.
Any string input to Marked.js is technically "valid". No matter what string you feed into
marked.parse
, you will get some HTML out. It just might not be the HTML you want (garbage in, garbage out). I.e., you could domarked.parse("ajl*gA#**@(*()**gg**s*G@(AUG)J*")
and you would get some HTML (<p>ajl<em>gA#**@(</em>()<strong>gg</strong>s<em>G@(AUG)J</em></p>
) out. There's nothing secretive about it.