Live data from Hacker News

Show HN: HyperApp – 1k JavaScript framework for building web applications

github.com

81–90 of 169 posts

Re: Show HN: HyperApp – 1k JavaScript framework for building web applications

#81
post #69
post #50

Earlier quoted context omitted.

Just out of curiosity, what was your use case that you deemed this a better option than react for?

We use Hyperapp to power our most complex UIs (decision trees, onboarding sequences, etc.). We didn't need any of the existing React ecosystem for that, and by removing React, we saw several benefits: 1. Smaller library for faster page loads 2. Simpler API, docs and library made it easy to get started and understand what's happening behind the scenes as well as debug any issues we faced 3. We aren't supporting a proj…

Why not Preact?

Re: Show HN: HyperApp – 1k JavaScript framework for building web applications

#82

This makes me almost want to write web code again - compared to things like React and Angular 1-2-3-4-5-6.

Not sure what your problem with React is, is it the configuration?

React is a ghetto, basicly + vdom has its own size. IMO thing like hyperhtml or lit-html are the way forward - especially with new templating proposals. Not to mention react is not interoperable really with other solutions - I'd expect webcomponents win long term, since they are built into clients.

Re: Show HN: HyperApp – 1k JavaScript framework for building web applications

#83

I've seen "Show HN: HyperApp" type of submissions at least 5 times earlier. Congrats, you made a 1Kb JS library. Please stop spamming HN though. https://hn.algolia.com/?query=hyperapp&sort=byPopularity&pre...

I don't even get why it is important that it's 1kb. Give me a library with great API and easy to use. Nobody cares if library is 1kb or 100kb (minified).

> Nobody cares if library is 1kb or 100kb (minified).

You do if your app needs to be mobile-friendly. 100kb can easily add an extra second or two to the page load on a bad enough mobile connection.

Re: Show HN: HyperApp – 1k JavaScript framework for building web applications

#84
post #19

This is an exceptionally simple library to use in place of React. Both its performance and the development experience have been great. My company's been using it in production for more than a year now without any issues. Highly recommend giving it a look.

people should really give it a book

Re: Show HN: HyperApp – 1k JavaScript framework for building web applications

#85
post #61

Earlier quoted context omitted.

> Nearly identical. lit-html uses ` `s and cloning, so that it doesn't have to do any expensive VDOM diffs. So… it's not doing reconciliations and is just replacing the entire tree on every render, losing things like cursor position and forcing the browser to re-render and re-layout the entire thing?

Highly recommended to watch https://youtu.be/Io6JjgckHbg

Yeah nah, I'm not watching a 30mn video on something I'm not interested in to get what amounts to a 2-paragraphs answer.

Re: Show HN: HyperApp – 1k JavaScript framework for building web applications

#86
post #81
post #69

Earlier quoted context omitted.

We use Hyperapp to power our most complex UIs (decision trees, onboarding sequences, etc.). We didn't need any of the existing React ecosystem for that, and by removing React, we saw several benefits: 1. Smaller library for faster page loads 2. Simpler API, docs and library made it easy to get started and understand what's happening behind the scenes as well as debug any issues we faced 3. We aren't supporting a proj…

Why not Preact?

It came down to preference. I find HyperApp's codebase simpler to read/reason about (it's a pretty straightforward single file), and I prefer its API over React/Preact's.

Re: Show HN: HyperApp – 1k JavaScript framework for building web applications

#87

Earlier quoted context omitted.

I don't even get why it is important that it's 1kb. Give me a library with great API and easy to use. Nobody cares if library is 1kb or 100kb (minified).

> Nobody cares if library is 1kb or 100kb (minified). You do if your app needs to be mobile-friendly. 100kb can easily add an extra second or two to the page load on a bad enough mobile connection.

It isn't just on bad connections: https://medium.com/dev-channel/the-cost-of-javascript-84009f...

Re: Show HN: HyperApp – 1k JavaScript framework for building web applications

#88

Another Virtual DOM thing - which is obviously wrong.

Can you explain (or link some source) why is Virtual DOM wrong? Actually curious.

Hi. I'm the author of Mithril (one of the virtual dom frameworks mentioned elsewhere in this thread), so I think can answer that.

To be honest, there's nothing inherently "wrong" with it. There are various techniques to implement templating engines and they all have pros and cons.

Lately, VDOM performance in micro benchmarks has sort of plateaued, and recently non-vdom systems like Svelte (an AOT compilation system) and Surplus (a KVO system) have been making some splash as potential candidates to surpass vdom performance. One could argue that it would be "wrong" or "a waste of time" to try to one-up template performance by attempting to make a new vdom implementation because existing ones are pretty much as optimized as they can be. Since there hasn't been nearly as much effort put into alternative algorithms, it probably would be more fruitful to explore a non-vdom approach instead.

Do note though that I'm talking about R&D sort of stuff above. For people building actual apps, vdom performance is generally good enough for a vast majority of real-world use cases (evidenced by React's popularity) and one of its appeals is that it lends itself to being manually optimizable it if you do end up with a ridiculously ginormous DOM.

Re: Show HN: HyperApp – 1k JavaScript framework for building web applications

#89
This is amazing. Very similar to ideas I was exploring when building Helix (https://github.com/josephluck/helix) however I went down the fully typesafe route, which is nice but the API isn't as clean as hyperapp. If it wasn't for reacts ecosystem, I'd consider using hyperapp for more projects.

Re: Show HN: HyperApp – 1k JavaScript framework for building web applications

#90

This one is 25 bytes gzipped http://vanilla-js.com/

vanilla-js is really powerful! One incredible feature they don't even list yet is Web Components.

Preach! we on the vanilla JS train can speak of it's performance, easy to deploy. . and template literals can your app scoring 90s on lighthouse, as if server rendered.
Post reply on HN