Skip to content

Latest commit

 

History

History

content

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 

@welshman/content version

Utilities for parsing note content.

import {parse, render} from '@welshman/content'

const content = "Hello<br>from https://coracle.tools! <script>alert('evil')</script>"
const html = parse({content}).map(render).join("")
// => Hello&lt;br&gt;from <a href="https://coracle.tools/" target="_blank">coracle.tools/</a>! &lt;script&gt;alert('evil')&lt;/script&gt;