javascript - How can I real time parse content in a textarea as the user types like how stackoverflow does it? -
when adding post @ stackoverflow, enter text on edit window, , appears modified in display window. instance...
- if type
**some text
, see **some text (**some text
) - if type
**some text*
, see *some text (*<em>some text</em>
) - if type
**some text**
, see some text (<strong>some text</strong>
)
how this? there jquery solution?
this syntax writing in comments called markdown. there few javascript markdown parsers. https://code.google.com/p/pagedown/ example
Comments
Post a Comment