Skip to content

Commit

Permalink
[WIP] Refactor to remove regular expressions
Browse files Browse the repository at this point in the history
...in favour of an algorithmic approach.

*   [x] `yamlFrontMatter`
*   [x] `newline`
*   [x] `code`
*   [x] `horizontalRule`
*   [x] `escape`
*   [x] `deletion`
*   [x] `break`
*   [x] `inlineText`
*   [x] `fences`
*   [x] `heading`
*   [x] `lineHeading`
*   [x] `blockquote`
*   [x] `list`
*   [x] `html`
*   [x] `definition`
*   [x] `footnoteDefinition`
*   [x] `looseTable`
*   [x] `table`
*   [ ] `paragraph`
*   [x] `autoLink`
*   [x] `url`
*   [x] `tag`
*   [x] `link`
*   [x] `reference`
*   [x] `shortcutReference`
*   [x] `strong`
*   [x] `emphasis`
*   [x] `inlineCode`

New features:

*   Add support for `silent` mode on tokenisers, which will
    detect whether a given value would match that tokeniser,
    but without eating any actual content.

Regressions (either todo or in the subsequent major release):

*   Malformed HTML block elements are not supported.

Fixes:

*   Handles mismatched parentheses in links arguably better;
*   Fix continued block-quotes in non-GFM-mode;
*   Fix block-quotes followed by lazy definitions
    in commonmark-mode;

Todo:

*   A lot of places support escaped (a slash followed by another character),
    instead of allowing any character to be escaped, only certain characters
    should be supported (e.g., all ASCII-character for commonmark-mode, and
    several separate subsets on other flavours);
*   blockquotes followed by partially lazy fences in commonmark-mode are still
    not perfect.

[ci skip]
  • Loading branch information
wooorm committed Dec 9, 2015
1 parent 2f27616 commit c56b122
Show file tree
Hide file tree
Showing 18 changed files with 4,766 additions and 2,119 deletions.
2 changes: 1 addition & 1 deletion .jscs.json
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@
"else"
],
"requireLineFeedAtFileEnd": true,
"maximumLineLength": 78,
"maximumLineLength": 79,
"requireCapitalizedConstructors": true,
"safeContextKeyword": "self",
"requireDotNotation": true,
Expand Down
20 changes: 0 additions & 20 deletions example.js

This file was deleted.

59 changes: 2 additions & 57 deletions lib/expressions.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit c56b122

Please sign in to comment.