JuliaWeb / Hyperscript.jl

Hyperscript: A lightweight DOM representation for Julia
Other
101 stars 11 forks source link

Benchmarks #19

Open aminya opened 4 years ago

aminya commented 4 years ago

Is there any benchmark for using Hyperscript compared to EzXML (libxml2) for example?

I have made a package called AcuteML that defines a couple of XML utilities for manipulating DOM: https://github.com/aminya/AcuteML.jl/tree/master/src/xmlutils

I wanna know if Hyperscript offers more performance or other advantages over other packages.

yurivish commented 4 years ago

Hi @aminya, I would be surprised if Hyperscript offers performance advantages over any package specifically written to have good performance. I’m the primary author and I wrote it to have the behavior I wanted without working too hard on good performance, since my use cases at the time were not ones where the output or manipulation of DOM was a bottleneck.

I know @SimonDanisch is someone who has thought about performance more, so maybe he would be interested in hearing about your package.

SimonDanisch commented 4 years ago

I'm mainly using Hyperscript for it's nice & easy syntax to define HTML DOMs in pure Julia - so I find it quite hard to compare to e.g. EzXML, which is far away from that use case... The performance is quite good, considering that @yurivish hasn't put much focus on it ;) The biggest problem I could find is: https://github.com/yurivish/Hyperscript.jl/pull/13 Which, now that you remind me, I should try to merge this week!

aminya commented 4 years ago

Thank you for your answers! I look forward to some benchmark after #13 is merged! 😄 You can compare it to this from AcuteML:

https://github.com/aminya/AcuteML.jl/blob/3f32c7580b64bb888004f7e7d213704ff6daf581/benchmark/bench.jl#L88