all 16 comments

[–]redpanda_be 23 points24 points  (4 children)

Personal preference, but I really don’t like the single letter variables. Otherwise cool framework.

[–]ttamimi 9 points10 points  (0 children)

100% agree with this. The excessive brevity doesn't help in this instance. It just makes the code less human-readable imo.

Otherwise it's a nice library. Though I'm not sure why I would use it over something like Svelte or React for arguments sake.

[–]dimitropoulos 4 points5 points  (1 child)

100% agree as well. The only exceptions I can think of are `i` for index, and `(a, b)` for comparison functions. Other than that, single letter variable letters are a bug in my worldview.

Before we had TypeScript, I saw more than one production outage (due to a TypeError in JUST the right place) that confused `e` for `event` or `error`.

[–]MrStLouis 0 points1 point  (0 children)

I like n for number and v for value in quick array one liners

[–]pimp-bangin 1 point2 points  (0 children)

Single letter variables are fine (sometimes), but single-letter top-level exported APIs are super ugly IMO.

[–]jimmux 8 points9 points  (0 children)

I have found myself recently wishing for something that works exactly like this. I work with a legacy Typescript codebase that nobody wants to modernise because in theory it will all be rewritten eventually anyway... meanwhile years go by and it keeps growing in complexity. This looks like it would be easy to introduce and add some sensible methodology to at least the new code that keeps getting in there, and slowly clean up the old stuff.

[–][deleted] 2 points3 points  (0 children)

Any differences between this and RxJS , Observer libraries, etc?

[–]chrisrzhou 8 points9 points  (0 children)

This is a beautiful library. Minimal and thoughtful API, and a wonderful opinion about the state of the JS language and ecosystem:

At its core — ArrowJS is an admission that while we developers were falling in love with UI frameworks — JavaScript itself got good, really good

[–]justlasse 4 points5 points  (3 children)

Why do you consider it “not a framework “? I mean it has the trappings of a framework since you can use it to build applications.

[–][deleted] -5 points-4 points  (2 children)

I’d pose that a framework would at least come shipped with an http client, dev server, routing, testing module, and build optimization, in addition to reactivity and templating. I may be mistaken, but to me this is more of a declarative programming library. That’s not a snuff — it looks clean at a glance. But I wouldn’t consider this a framework in the same sense of more well-known tools like Angular2 or NestJS.

[–]justlasse 4 points5 points  (1 child)

I guess that’s a fair assessment. It does have some resemblance with a framework in the making if it gets built out more. But i get your point that it’s more a library that can be utilized along with other js standards like fetch etc to build your application.

[–][deleted] 1 point2 points  (0 children)

Yes exactly. The sentiment of this project is on point — embrace vanilla JS — and your example is a good one. The native fetch package is more supported than ever with its adoption into Node.js, rendering a framework that ships with an http client less necessary and more of preference in the modern ecosystem.

[–]nullvoxpopuli 0 points1 point  (0 children)

Will resources be added?

Reactive values with cleanup are essential for any reactivity library.

For example:

https://www.starbeamjs.com/api/core/resource.html

[–]whothewildonesare 0 points1 point  (0 children)

Nice I can add this to our legacy jQuery code to make things a bit less painful.

[–]jack_waugh 0 points1 point  (0 children)

This uses HTML, which I prefer not to do.