Skip to content

Turns an HTML string into a analogous JS Object

License

Notifications You must be signed in to change notification settings

TomZou/HTMLparser

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

HTMLparser

Turns an HTML string into an analogous JS Object

Usage

To get HTML as an Object

foo = HTML2Obj(string);

To turn the object into a DOM element

bar = Obj2HTML(foo);

Note: Obj2HTML takes an additional argument of a DOM element. It will append to this element.

//appends foo to document.body
bar = Obj2HTML(foo,document.body);

About

Turns an HTML string into a analogous JS Object

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 92.5%
  • HTML 7.5%