Skip to content

Manvel/markdown-it-html-entities

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

markdown-it-html-entities

Build Status

Currently markdown-it follows CommonMark specs which requires HTML Entities replacement with Unicode Characters and currently there is no native way to disable HTML Entities autoconversion.

This plugin disables the automatic HTML Entities to Unicode conversion in markdown-it and let the browser display expected character using HTML Entities accordingly, avoiding unexpected character conversion which might not play well if you would like to integrate the Markdown output with the system that expect HTML Entities and in general it's just adding support for using HTML Entities in the Markdown.

Installation

npm i markdown-it-html-entities

Usage

const markdownIt = require("markdown-it");
const htmlEntities = require("markdown-it-html-entities");

const markdown = markdownIt().use(htmlEntities);

const result = markdown.render("curly { & } brackets");
console.log(result); // <p>curly &#123; &amp; &#125; brackets</p>

About

Disable HTML entity to unicode autoconversion in markdown-it

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published