You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I recently upgraded to remarkable 2.0.1 from 1.7.3, the upgrade was successful on web but on mobile with react-native, whenever there are html entities contained in markdown, it fails at decodeEntity.
Sample String The number 15 is < number 16
Expected Output <p>The number 15 is < number 16</p>
But failing with stack trace:
ReferenceError: document is not defined
at decodeEntity (http://localhost:8081/index.bundle?platform=ios&dev=true&minify=false:503745:28)
at Array.entity (http://localhost:8081/index.bundle?platform=ios&dev=true&minify=false:508195:25)
at ParserInline.tokenize (http://localhost:8081/index.bundle?platform=ios&dev=true&minify=false:508259:22)
at ParserInline.parse (http://localhost:8081/index.bundle?platform=ios&dev=true&minify=false:508284:10)
at Array.inline (http://localhost:8081/index.bundle?platform=ios&dev=true&minify=false:504876:22)
at Core.process (http://localhost:8081/index.bundle?platform=ios&dev=true&minify=false:505277:15)
at Remarkable.parse (http://localhost:8081/index.bundle?platform=ios&dev=true&minify=false:508434:15)
at Remarkable.render (http://localhost:8081/index.bundle?platform=ios&dev=true&minify=false:508440:38)
at postBodySummary (http://localhost:8081/index.bundle?platform=ios&dev=true&minify=false:332114:19)
at getPostBodySummary (http://localhost:8081/index.bundle?platform=ios&dev=true&minify=false:332127:14)
Code Snippet
const entryBody = 'The number 15 is < number 16'
const md = new Remarkable({
html: true,
breaks: true,
})
// Convert markdown to html
let text = md.render(entryBody)
I recently upgraded to remarkable
2.0.1
from1.7.3
, the upgrade was successful on web but on mobile with react-native, whenever there are html entities contained in markdown, it fails at decodeEntity.Sample String
The number 15 is < number 16
Expected Output
<p>The number 15 is < number 16</p>
But failing with stack trace:
Code Snippet
Environment
The text was updated successfully, but these errors were encountered: