Live data from Hacker News

State of JavaScript 2020

2020.stateofjs.com

61–70 of 189 posts

Re: State of JavaScript 2020

#61
post #9

As someone who is relatively outside of the JavaScript ecosystem, I had the following realization yesterday when I was reviewing this: JavaScript has what I would consider two distinct flavors of "back-end" frameworks. It has frameworks like Express and Koa, which I would consider traditional back-end frameworks. These are designed around handling HTTP requests and providing dynamic responses in myriad forms: rendere…

Yeah, that's about right. I was also surprised to see Gatsby and Next.js listed in backend, but it makes a weird kind of sense. I think "static site generators" would be a better umbrella, but it's a shady distinction for sure.

And your summary of Next.js API Routes is correct as well. As an example, I have a site built in Next that needs to be able to query data off of a SQLite database. Back in the old days I would have set up a simple PHP server of some kind… today I might have knocked something crappy together in Node… but in Next, you just point at a route, grab the SQLite database out of the filesystem, and look over your query parameters. It's really neat.

Re: State of JavaScript 2020

#62
post #41

Earlier quoted context omitted.

> All the front end devs are like, "You have to wait how many minutes for compile times?" for instance. This is a shocking argument coming from any front end dev. Since when is static type checking, working on serious big repositories that take time to compile, have proper architecture with hundreds if not thousands of programmers working on it comparable to 3 frontend folks working on a web application? There is so…

I think you have a fairly dated understanding of what front end is, it's scale, and the complexity of delivering an experience that's fast and well optimized. These days front end engineering can be every bit as rigorous and complex as back end engineering. The constraints are a bit different, and the environments are very different, but the scale and complexity of engineering is not.

I believe you might have a slightly biased view of what front-end development largely looks like. What you're describing is the type of front-end development that goes on at the organizations that actually develop these frameworks.

The vast majority of front-end development outside of that world is misguidedly trying to mimic that complexity on their static business informational page they maintain with a duct taped mess of bad practices everywhere.

Now if you take a look at development outside of front-end and go to some large non-tech, mid-sized, or small business you'll probably also find poor practices (from my experience), but nothing like the mess I see in these same organizations trying front-end development now.

Re: State of JavaScript 2020

#63

Earlier quoted context omitted.

Javascript tooling is crazy. A couple years ago I tried to build an older Ionic app that nobody had touched for six months, and the build had just bitrotted. Something somewhere in the dependencies hadn't been screwed down tightly enough, and everything was broken. I feel like the Yarn 2 package manager is a good move towards in making frontend development more stable (The "Plug'n'Play" feature allows you to store yo…

> having an extremely stable platform that never breaks backwards compatibility is exactly what the web needs to be. Frontend development tooling would be so much better if it was more like browsers. This is precisely my fear [1]. I need something robust and will continue to work for a good foreseeable future. Do you recommend Angular for frontend? I've just tried React and Svelte, but I am told to stay away from Ang…

I've found Angular to be more effective than React at companies with a "developers are cogs" mentality. Angular has opinions about how things should be built and there is a lot of supporting material out there on how to do things the "Angular" way. It's much more heavy weight that React because it's a more comprehensive tool whereas React is just the rendering portion. If you're the type of developer who can push the boundaries of what's being done on the web, you'll be happier with React or other tools. If you want to just follow instructions and tutorials online for how to build a website use Angular or even a CMS.

Re: State of JavaScript 2020

#64

Cliche rant coming up: as a backend engineer, recently started working on frontend. Is this how yall do things? Everything so far feels less mature, thinly pieced together, barely holding up, fast moving, unnecessarily bloated, and no care for longevity, robustness and discipline. Seems like every thing is on Youtube, no real good books (yeah, go ahead and search for "React JS" books on Amazon and see if you find som…

I consider myself to traditionally be a backend engineer, though this has more been something I fell into rather than chose.

I admit I feel I share some of your frustrations. In the past I have written production frontends in Angular and experimented with Vue and React. Out of all of them I found React to be the most enjoyable, but even then I still struggled with project setup and found the tooling confusing. I even quite like TS as a language, but I feel it's still quite limited by the fact it transpiles to JS.

Recently, I discovered yew [0]. It is a Rust framework for building frontends using wasm. I really appreciate the robustness that Rust brings such as ownership checks and ADTs. I don't think it's for everyone, but it may be worth looking at if you perhaps find modern frontend development confusing frustrating. I've found it to be quite the breath of fresh air.

If you do decide to have a look I found the examples [1] and getting started guide [2] very informative.

[0] https://github.com/yewstack/yew

[1] https://github.com/yewstack/yew/tree/master/examples

[2] https://yew.rs/docs/en/getting-started/project-setup

Re: State of JavaScript 2020

#65
post #41

Earlier quoted context omitted.

> All the front end devs are like, "You have to wait how many minutes for compile times?" for instance. This is a shocking argument coming from any front end dev. Since when is static type checking, working on serious big repositories that take time to compile, have proper architecture with hundreds if not thousands of programmers working on it comparable to 3 frontend folks working on a web application? There is so…

I think you have a fairly dated understanding of what front end is, it's scale, and the complexity of delivering an experience that's fast and well optimized. These days front end engineering can be every bit as rigorous and complex as back end engineering. The constraints are a bit different, and the environments are very different, but the scale and complexity of engineering is not.

Do you ever wonder whether we cause the complexity ourselves. Did we need React? Flux? Graphql? Since we introduced these concepts we needed to rethink a huge amount of other stuff to keep it performant.

Compare the simplicity of jQuery vs a modern tool chain. Like creating a form. It gets pretty insane with React. And jQuery would be dead simple.

You have to stay on the bandwagon because it’s where the community is now. There’s certainly a lot more fun to be had remaking everything in React though.

Re: State of JavaScript 2020

#66

Cliche rant coming up: as a backend engineer, recently started working on frontend. Is this how yall do things? Everything so far feels less mature, thinly pieced together, barely holding up, fast moving, unnecessarily bloated, and no care for longevity, robustness and discipline. Seems like every thing is on Youtube, no real good books (yeah, go ahead and search for "React JS" books on Amazon and see if you find som…

How is JS and it’s ecosystem any less mature than Go or Rust? There’s a plethora of mature frameworks, build tooling and patterns on the frontend as well as a lot of cutting edge competition that creates a lot of noise. The point is though that there’s just a lot going on in JS world. Doesn’t mean it’s any less than any other language and it’s ecosystem.

The bar for participation is dramatically lower for JS. I think that's unequivocally a good thing, but it does lead to explosions of libraries and toolchains of questionable quality which iterate rapidly. There is SO MUCH JS stuff out there that even just the bad stuff greatly outnumbers what you have in Rust or Go. It's the same reason why PHP has such a bad reputation. It was used and abused by non-developers just getting shit done for years that if you casually looked around the PHP world 10 years ago everything looked like crap. Quite frankly I'm over the elitism that so often accompanies these discussions where people ignorant about how other domains work make huge assumptions about the quality of said ecosystem. It's classic Dunning Kruger.

Re: State of JavaScript 2020

#67

Earlier quoted context omitted.

I think it's about individual maturity than tech-stack. Frontenders are likely to be younger than backenders, and some of the traits you observed are a result of that.

Maybe,but it's not the kids who sit at the top of the food chain in places like language committees, standard agencies, or even the CTOs of this world ( the real ones,not those of 5 person startups) where things get decided for years or even decades ahead.

I'm not blaming kids. And the constant churn is not a bad thing.

Next time I build a team, I might consciously choose a mix of stable experienced senior devs, and perhaps a couple of young ignorant-but-brave junior devs. Horses for courses.

Re: State of JavaScript 2020

#68
post #5

Some takeaways of mine; - Typescript keeps strengthening its position as industry standard. - Svelte is hyped, but is it battle tested enough? - Testing Library is quite new in the town but already the runner up testing tool. - In terms of data management, GraphQL holds its position on the top while good-ol Redux kept losing interest. What are yours?

> - Svelte is hyped, but is it battle tested enough? Try asking the NYTimes how it's working out for them

First, I hate paywalled news sites. Second it sounds more like inbreed than a battle thanks to reddit friends.

`The creator of Svelte, Rich Harris, actually works there!`

`I think it was a passion project from a web dev at NYT`

I would still like to hear more about it, will dig further, thanks.

Re: State of JavaScript 2020

#69
It seems like the overall trend is that people are getting more and more unsatisfied with the current landscape now that a little bit of the sugar high from first wave of shiny new tech is starting to fade away.

The jump from "whatever js was in 2014" -> angularjs junk -> react/vue/angular was pretty big.

But now the glamour is gone and we're moving into the phase of actually having to maintain some of the things we built and the wear from bad decisions is starting to show.

-----

Svelte also seems like the cool new kid on the block. Svelte surprises me in how much people fawn over it. I really don't understand the hype since I don't think it's a huge jump forward, and there's also a lot of "misunderstandings" about it in comparison to other frameworks.

Like one thing I've seen a lot is people mention how it requires less code, but it's not that much smaller. It just looks smaller for small test cases where there are like 8 lines of code or because svelte makes stylistic choices that have tradeoffs that aren't immediately obvious. If you take a loot at react/vue, they're not that much bigger for realistic component size.

Anyways, front-end framework discussion is long and muddled and confusing. I wanted to make a point of how svelte people often confuse the engineering/implementation vs the philosophical approach in frameworks. Things like svelte's bundle size being smaller is because other frameworks don't put as much emphasis on it. I was going to say that react is bloated and that preact is much smaller, but looking it up it seems like somehow react is 2.6kb, preact is 4kb, and svelte is 1.5kb. Angular is 62kb. Which proves two points, react/vue can be smaller if it wants, the approach it takes doesn't limit it and that things move so fast that somehow preact makes bigger bundles than react.

Re: State of JavaScript 2020

#70

If the healthcare sector would apply the same ideas and principles of the front-end industry, it'd look like this: oh,look, it's a pen! Why don't we combine it with a scalpel and an angle grinder for our next surgery? Front-end is an absolute shit show with all the html/css/js mixture.

Your opinion is unoriginal and unhelpful. Show me another platform with the reach and usability as the web.
Post reply on HN