Browse Source
Given input like this: hi<p>_</p>there avoid leaving a dangling text blob outside of any "p" section like this: <p>hi</p><p>_</p>there Instead, auto-open a new "p" section so the final text blob ends up properly wrapped like so: <p>hi</p><p>_</p><p>there</p> This reflects the actual rendering behavior of the client "user agent" (aka browser) which would end up supplying the missing <p>...</p> wrapper in any case. By doing this the output better reflects the way the markup actually renders. The heuristic used to auto-open the "p" section may not always auto-open a "p" when it should, but it should never auto-open a "p" when it shouldn't. Signed-off-by: Kyle J. McKay <mackyle@gmail.com>master
Kyle J. McKay
4 years ago
1 changed files with 9 additions and 1 deletions
Loading…
Reference in new issue