evilstreak/markdown-js — pull request #64 by matthewkastor (2012-10-16 01:11:49+00:00)
Title: Fix for issue #58 "Windows linebreak issues"

Fix for issue #58 "Windows linebreak issues"

I installed markdown 0.4.0 through npm. While using md2html from the commandline on windows, I noticed that the program chokes on end of line marks that windows uses `\r\n`. I also noticed this same problem when using JSDoc3 which, has incorporated markdown-js into its source.

This pull request fixes the issue by replacing line breaks of the form `\r\n`, `\n`, and `\r` with the line break `\n`. I followed the process to the `split_blocks` function and inserted the filter on input text to occur just before it is processed. I believe this is the point in code that all input text has to pass through and that by affecting things here I've resolved the issue for all cases without introducing any bugs. Of course I could be wrong.

I commit these Glorious updates to make stuff do things, better!