Live data from Hacker News

Ask HN: Why is everything in JavaScript changing so fast?

news.ycombinator.com

131–140 of 303 posts

Re: Ask HN: Why is everything in JavaScript changing so fast?

#131

Earlier quoted context omitted.

To a large extent this is true because the javascript community is busy with the re-invention of all of computer history, only without applying all of the lessons learned. Activity does not equate quality.

Give me a break. The entire internet and software landscape is changing and everyone is in a constant rush to stay current. You make it seem like it's some kind of concerted effort to insult the sensibilities of good, proper software engineers who know the right way to do things. Everyone is just trying to do the best they can with the incredibly complex stack of technologies in play today.

"The entire internet and software landscape is changing"

Really? Is it Web 4.0 now?

People are changing the stack because they don't know any better and trying to justify their salary. That's the bottom line. The rush to stay current is just bandwagon-hype.

Re: Ask HN: Why is everything in JavaScript changing so fast?

#132

Earlier quoted context omitted.

> explanation for why their platform / language / framework [...] did not become the de facto tool You're implying this happened to JS because of some merit. But it didn't, it was just sheer coincidence and bad luck (for most of us at least, including users).

Explain what the coincidence was ? There are alternatives everywhere (ActiveX, flash, java, visual basic IIRC). And yet here we are, with JS. I believe JS came here because it actually is the best language we have had in the web. It's so easy to throw shit arround, but let's be honest with ourselves, this isn't purely out of luck.

> I believe JS came here because it actually is the best language we have had in the web.

It is the only language we have had in the web (modulo some minor experiments). The only reason it's popular in the browser is because it's the only choice at all. The only reason it is used on the server is because some folks are familiar with it from using (overusing IMHO, but that's a different rant) it in the browser and are not familiar with the advantages of using any other language.

I've written this before, but sometimes in my most morose moment I like to imagine what the world might have been like had Brendan Eich been permitted to implement a Scheme instead. And I don't even like Scheme!

Re: Ask HN: Why is everything in JavaScript changing so fast?

#133
post #94

Earlier quoted context omitted.

To a large extent this is true because the javascript community is busy with the re-invention of all of computer history, only without applying all of the lessons learned. Activity does not equate quality.

It's easy to sit back and critisize JavaScript and the web with dismissive comments like this. I have heard variations on these same memes for many years. But something that I almost never hear: critics offering a candid explanation for why their platform / language / framework - which maybe wasn't perfect but CERTAINLY compared to JavaScript was awesome - did not become the de facto tool across as diverse a spectrum…

> But something that I almost never hear: critics offering a candid explanation for why their platform / language / framework - which maybe wasn't perfect but CERTAINLY compared to JavaScript was awesome - did not become the de facto tool across as diverse a spectrum for delivering features / products / tools to users.

I believe that part of the reason is the ease of access to JS development. It allowed an inordinate amount of poorly trained devs to enter into the job market. Because you can quickly whip up fancy UIs and show them to unsuspecting non-techie types, you can quickly earn a reputation as a "computer whiz".

I think there were many de facto ways of doing things before this, none of which were perfect, but some of which followed better design principles.

If you look at software industries where security and stability is of utmost importance, you will not find these newer frameworks in use - nor the languages they use. I'm thinking life critical systems here.

Re: Ask HN: Why is everything in JavaScript changing so fast?

#134
post #73
post #47

Earlier quoted context omitted.

You seem to assume that A) Types are low level B) C++ and C are the only competition to JavaScript C) Not having to worry about types makes you faster or in any way better A) is simply refuted by looking at java or SQL. SQL is a very high-level language compared to other stuff, yet it's heavily typed simply to ensure that data is either valid or the query fails (SQL Injection is still valid data in this case) B) Take…

SQL is also a leaky abstraction, it would be much more simple if the database could just take any value and store it optimally. But at least you do not have to write: SELECT *string* foo, *string* bar FROM banana A INNER JOIN beer B ON *int* B.id = *int* A.id I want to correct myself though. In ES6 you can now go very low level and deal with raw bit buffers. My problem with Go and other languages is that you have to…

>it would be much more simple if the database could just take any value and store it optimally

Which completely misses the point, this is called a file system btw, but a SQL Databases is designed from the ground up to have a validation schema.

You simply cannot put data in a SQL database that is not conform to the schema on which the table is defined. You can't simply put a string into an int column but this also means that any data you may read from this column will always be an int no matter what.

It means that if your transaction completes, including large scale database upgrades, at no point where types violated and you can be sure that all data is valid (or deleted because you forgot the WHERE clause)

>In ES6 you can now go very low level and deal with raw bit buffers.

I doubt you can write to registers and manipulate memory allocation, that is actually low level.

Manipulating bits is something every turing machine emulator can do.

>My problem with Go and other languages is that you have to be verbose like str = string = "string";

Which shows me that you haven't bothered to actually look into any statically typed language because I know of no common language that uses this syntax.

Go actually infers the type if possible, you simply write `str := "string"` or `var str = "string"` and go will use the correct type.

You can do this even with complex objects no problem. You only need to define the type if it's non-obvious, like you want to use an interface but the assignment uses the raw type, but this is something now compiler can do (it would be guess work)

Furthermore, there is no sacrifice in productivity, actually the opposite.

You don't have to wonder if the parameters you receive will have the correct type. If your function signature is `func (int) int` you can only ever receive an integer and you can only ever return an integer.

>NodeJS (commonJS) module system that makes it possible to not write complexed code, because it's lexically scoped and do not have hidden globals.

Go actually has a very neat module system. It's rather simple; all uppercase fields and funcs are exported, everything else is private.

The architecture of the standard library in Go and the language itself discourage globals and encourage default global states which can be exchanged for user defined states seamlessly.

Check out logrus or any of the popular logging frameworks in go. You can either use the default logger which is globally exposed or you use a custom one and pass the variable.

>I'm willing to sacrifice that for increased productivity and simplicity.

If simplicity and productivity is your goal you should use one of the LISP variants like ClojureScript. Nothing beats a language which you can program to be more efficient for you.

And you probably should check out some Go code too, it's easy to understand even without knowledge of the language as long as you know some basic CS101 stuff.

Re: Ask HN: Why is everything in JavaScript changing so fast?

#135

The problem is that everything in JS exploded during just few years (Node was published in 2009), and it took few years to build tooling around Node to start utilising all this power. And then everyone started to build "rich" web applications (it is called differently every year), with the "best" tool existing. I personally see two major problems – usually cool startups who can afford using the bleeding edge will die…

Soon we'll have trouble hiring Angular 1 devs to maintain legacy code, like COBOL. Except COBOL started in 1959, not 2009.

50 years later and we still haven't learned.

Re: Ask HN: Why is everything in JavaScript changing so fast?

#136

The problem is that everything in JS exploded during just few years (Node was published in 2009), and it took few years to build tooling around Node to start utilising all this power. And then everyone started to build "rich" web applications (it is called differently every year), with the "best" tool existing. I personally see two major problems – usually cool startups who can afford using the bleeding edge will die…

Soon we'll have trouble hiring Angular 1 devs to maintain legacy code, like COBOL. Except COBOL started in 1959, not 2009.

Angular 1.0, June 2012

https://github.com/angular/angular.js/releases?after=v1.0.4

...

And I actually prefer ng-1 to the transpiling mess that is ng-2, as well as preferring to use functional composition rather than pseudo-static classes for the controller logic.

https://github.com/roboprog/ang-prog-enh

Re: Ask HN: Why is everything in JavaScript changing so fast?

#137
post #87

Earlier quoted context omitted.

What's wrong with native apps? They use less memory, battery, and processor than an interpreted stack. They can be more responsive than the hardwired 16ms latency built into the browser. If you need network it's not hard to open a socket. The browser itself is a native app opening sockets. In pretty much every respect, native apps are better for the user than web apps. The person that benefits the most from web apps…

>What's wrong with native apps? Because you really don't need a native application to look up the time the local Thai place is open or if the local independent movie theater has a showing tonight. Installing two native apps to do that is burdensome on consumers and producers

You don't need web applications to do that either. Simple HTML will do.

Re: Ask HN: Why is everything in JavaScript changing so fast?

#138
post #84

Earlier quoted context omitted.

> Dude, comeon. The browser has evolved a lot as a platform, as has the hardware power of computers running them. Yes. It has evolved to counter-balance those advances in hardware power, in order to provide a sub-par 2000 native desktop application experience in a 2016 browser sandbox. > Maybe we're re-writing computer history Maybe? > but if that's the case then it's because we have to migrate everything to javascri…

We have to rewrite everything in JS because JS is the language that runs on browsers. :) If you were asking a higher-level why (why do we have to use the browser), look rer's sibling comment. I wrote the phrase "wise old timers" with respect-- y'all truly have things to teach us. But it often feels that y'all just want to complain about how we're doing things wrong, rather than actually helping. I suspect that "old t…

>We have to rewrite everything in JS because JS is the language that runs on browsers.

Not much of an argument. We already have 24/7 internet connected laptops, tablets and smartphones, which is were those browsers run in the first place anyway.

Perhaps we could, and I'm going on a limp here, just cut the middleman and run on the metal?

If the problem is discoverability/installation/security etc we could focus on app stores and sandboxes (which modern OSes also have both), instead of rewriting everything on the web.

>* But it often feels that y'all just want to complain about how we're doing things wrong, rather than actually helping.*

Well, you first stop someone from drowning and then you show them how to swim...

Re: Ask HN: Why is everything in JavaScript changing so fast?

#139
post #115

Earlier quoted context omitted.

quantity !== quality

There is a (perhaps apocryphal) story about the art class which was separated into 2 groups - one group worked on a single project all semester and the other group worked on a new project every day. People in the group that worked on a project every day produced better work than people in the "single project" group. My google-fu is weak, so I cannot find the reference. I'm not suggesting that the Javascript ecosystem…

This is the running premise behind the book Art and Fear, which basically concludes that iteration with quality feedback is the best way to develop your abilities and produce your best work. That is, quantity is the best path to quality.

https://www.amazon.com/Art-Fear-Observations-Rewards-Artmaki...

Re: Ask HN: Why is everything in JavaScript changing so fast?

#140
post #86
post #4

It may not be the common view, but I think that what you are witnessing is, to a certain extent, "deliberate". Every framework has a "sponsor". Every strong "sponsor" either has a vested interest in the web, or, a vested interest in some other platform with which the web competes. The importance and power of the web are obvious. So, it is a dance. "Embrace, extend and extinguish". And, hop, here we go again.

What do you mean by "deliberate"? It sounds like you are hinting at some kind of bad faith or at least perverse incentives but I can't tell what exactly.

There is no "bad faith". There are "diverging faiths". JavaScript frameworks as an analogy for life :)
Post reply on HN