Live data from Hacker News

Hyperapp – A tiny framework for building web interfaces

hyperapp.dev

131–140 of 198 posts

Re: Hyperapp – A tiny framework for building web interfaces

#131
post #101

Earlier quoted context omitted.

Setting up Webpack and Babel isn't so bad, these days, and you really only have to do it one time and then you can reuse the setup in other projects. Plus, once you've done it, Typescript is easy to slot in, and that by itself makes the effort worthwhile.

I can highly recommend you watching this talk: https://github.com/matthiasn/talk-transcripts/blob/master/Hi... It explains very well why is something being easy shouldn't be the main metric, when choosing some technology. In this case you are advocating to pull in webpack (28MB, 348 packages from 210 contributors), @babel/core (12MB, 54 packages from 60 contributors), typescript (53MB, 11 packages, 4 contributors), t…

If you are doing back compat for old browsers, Babel is necessary anyway.

Typescript is a choice independent from anything else.

There are alternatives to Webpack, none of which have gained traction, possibly because developers appreciate other features that webpack provides out of the box.

But, you are complaining about the developer tools, why? The source code size of emacs/vscode/vi is just as relevant, or the size of the linter, or the complexity of whatever build environment is used to deploy code to production.

All of those require upgrading and maintenance, and occasionally have bugs!

Re: Hyperapp – A tiny framework for building web interfaces

#132
post #2

How is it 2x faster than react? Where does this claim come from?

Probably from here: https://krausest.github.io/js-framework-benchmark/current.ht...

Hyperapp does outperform React in most benchmarks (along with many other frameworks). Not sure how the "2x" was measured, though.

Re: Hyperapp – A tiny framework for building web interfaces

#133

So I have extensively used hyperapp (1 and 2) for hybrid mobile applications that run the cab of big rigs. We actually won best in show this year at Freight Waves for our two apps. These are medium/larger apps, with lots of functionality, need to hook into native device features (done with ionic capacitor, and custom plugins), and need to be fast, robust, and flexible. Hyperapp has allowed all of those things. Hypera…

Hey there, really happy to hear of the success you've had with Hyperapp. I've played with Hyperapp v1 in the past for small toy projects, and it was relatively easy to become productive with. I'm wondering if you have any open toy projects or boilerplate you could share for v2, as I'm looking to jump back on it when I get the chance, and would love to see what a scalable project skeleton looks like.

I do not have anything that is open as of now (but about to start a new project soon)

I would check out https://medium.com/hyperapp/a-walk-through-hyperapp-2-b1f642...

to get your toes wet though, good resource, also feel fee to join the hyperapp slack https://hyperappjs.herokuapp.com/ nice community and super helpful.

Re: Hyperapp – A tiny framework for building web interfaces

#134

Earlier quoted context omitted.

This deserves a much better answer, but I'll just say this for now. Svelte is declarative/imperative (but mostly imperative) and also not based on functional principles. React is definitely more on the declarative side. And Hyperapp is essentially Elm in JavaScript, so it's as declarative/functional/immutable as the definition allows for. Maybe the person that said Svelte was more declarative was only familiar with a…

What do you think the advantages and disadvantages are? I remember briefly looking into Hyperapp and mostly liking it, but still wasn't sure which JS framework is the best choice (the other one I liked was Vue). Some time after that I learned about Svelte and very quickly concluded that this would be my choice, everything just feels right about it. For the record, I've only done a small project in Svelte.

That's fine. If you're already happy with Svelte, I encourage you to explore more with it. Try building a couple of non-trivial projects and keep learning about your craft. If you're also into computer science, I recommend you look into functional programming if you haven't done so yet. Then look at Svelte again. Try React too. Check out Elm.

I can tell you that Hyperapp is not for everyone. If you want to write pure, immutable, functional JavaScript and think hard about client side app architecture (unidirectional state management, controlled side effects, toggleable subscriptions), then you'll love it.

If you are looking for a more accommodating, meet-in-the-middle kind of approach where you can mix programming styles, and don't want to think much about those things I mentioned above, then React, Vue, Svelte are all great choices.

V2 will be released in a few months, so do circle back to Hyperapp then to see how you like it again.

Re: Hyperapp – A tiny framework for building web interfaces

#135
post #50

Earlier quoted context omitted.

Text templates are the technology for web development. They are so much better than anything else that there's no comparison. There are some bad templates implementation, and some good ones. The original PHP and ASP are bad. But that doesn't mean templates are bad.

Text templates are a good idea, placing them into the middle of JavaScript code, not really.

I do agree with that. But on the case of JSX, it is located inside JS code, but is completely self-contained, thus, it's not as bad.

The original PHP and ASP are really singular beasts, people aren't creating things like those anymore.

Re: Hyperapp – A tiny framework for building web interfaces

#136
post #129

Someone got inspired by re-frame, I see :) I like the approach. Wondering if there's a way to get ever closer to hiccup (without having to resort to JSX) Also, letting the framework decide if a function inside the markup should be called or not gives opportunity for more optimizations that go beyond VDOM diffing. That would require an even more declarative approach. i.e. [h1, {}, [MyComponent, {}]] vs. h("h1", {}, My…

Yep, there's a feature called Lazy (will be renamed to memo for the official release) that allows you to do just that! :)

Re: Hyperapp – A tiny framework for building web interfaces

#137
post #70
post #50

Earlier quoted context omitted.

Text templates are a good idea, placing them into the middle of JavaScript code, not really.

I absolutely disagree, but I also feel it's unfortunate that HTML, CSS, and SQL aren't first-class citizens in most languages. It's strange to treat things backed by entire standards bodies and with fully developed ASTs as plain-text. It seems unnecessarily limiting, and I'm not sure why; For the sake of history? "Division of Concerns"? How is it that using libraries meant for string manipulation upon a standardized…

It's an evolutionary constraint. Text templates are initially much more useful than HTML and CSS ones, so people adopt the first, despite a bigger potential usefulness of the later.

The tendency for SQL is even weirder, it's for replacing it with languages that are much less useful for querying data.

Re: Hyperapp – A tiny framework for building web interfaces

#138

Bit of a Hyperapp fanboy here, so bare with me. First, I think Hyperapp can make both small and big applications, opposed to u/PufPufPuf's opinion. A lot of people have this opinion because they are more familiar with v1's wired-in actions, which can become quite unruly. In the latest version, actions are decoupled, and can be organized/extracted however you see fit. I've made a handful of applications in both v1 and…

( s/bare/bear/ )

Re: Hyperapp – A tiny framework for building web interfaces

#139

I have tried Hyperapp some time ago. It's usable for small apps, but the lack of ecosystem makes it unfit for anything larger -- as is usual for all niché JS frameworks. Funnily, the "ecosystem" page contains just Lorem Ipsum ( https://hyperapp.dev/ecosystem ) and the Awesome Hyperapp section for V2 is almost empty ( https://github.com/jorgebucaran/awesome-hyperapp )

> but the lack of ecosystem makes it unfit for anything larger What does this mean?

Lack of libraries, as sibling says. Any libraries that exist are not generally well supported relative to similar libs for popular frameworks. Much smaller community, much less ease at finding others who may have had similar issues. Fewer eyes on, fewer bugs picked up. Fewer contributors, slower fixes/updates. Docs there are tend to atrophy faster.

Developed with Hyperapp on big prod apps about three years; was used to inject small amounts of interactive functionality into existing apps (.Net with jQuery powered frontends). Sorta worked, nice, simple idea, but docs almost nonexistent at the time (to be fair there's very little to it), was in process of being dumped for React just as I was leaving (to work on apps with Elm frontends, which Hyperapp takes a lot from, and suffers from similar issues, heh)

Re: Hyperapp – A tiny framework for building web interfaces

#140

Bit of a Hyperapp fanboy here, so bare with me. First, I think Hyperapp can make both small and big applications, opposed to u/PufPufPuf's opinion. A lot of people have this opinion because they are more familiar with v1's wired-in actions, which can become quite unruly. In the latest version, actions are decoupled, and can be organized/extracted however you see fit. I've made a handful of applications in both v1 and…

( s/bare/bear/ )

You are absolutely correct!
Post reply on HN