At the end of the day I probably will maintain my own copy, with some
changes, of Markdown. I also don't want to break the syntax. One of my
previous mails I mentioned a way that makes the Markdown more useable (by
being able to usefully use nl2br on the Markdown'ed string) without breaking
the
Le 2008-07-22 à 2:47, Jurgens du Toit a écrit :
At the end of the day I probably will maintain my own copy, with some
changes, of Markdown. I also don't want to break the syntax. One of my
previous mails I mentioned a way that makes the Markdown more
useable (by
being able to usefully use
* Michel Fortin [EMAIL PROTECTED] [2008-07-22 12:40]:
Have you considered what will happen to code blocks with
`nl2br`?
That can be fixed by *replacing* newlines with break tags so
there aren’t any literal linebreaks. View Source won’t be pretty
but the browser rendering will be correct.
You can change [peg-markdown] to behave the way you want (without
problems in code blocks) just by adding one line:
--- a/markdown_parser.leg
+++ b/markdown_parser.leg
@@ -384,6 +384,7 @@ Entity =( HexEntity | DecEntity | CharEntity )
{ $$ = mk_str(yytext); $$-key = HTML; }
Hello!
On the markdown site it is written: Markdown’s syntax is intended for
one purpose: to be used as a format for writing for the web., although
recently I moved from Emacs Muse to Markdown markup for writing my study
notes and plan to use it for writing technical documentation as well.