Skip to content

GitbookIO/html2hs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

html2hs

NPM version Build Status

Parse HTML to hyperscript (for virtual-dom).

var html2hs = require('html2hs');

var hscript = html2hs('<h1>Hello World</h1>');

// hscript = 'h("h1", [ "Hello World" ])'

html2hs also accept an option argument:

{
    // true: pre tags will be parsed like other tags
    pre: false
}

About

Convert HTML to hyperscript for virtual-dom

Resources

License

Stars

Watchers

Forks

Packages

No packages published