Live data from Hacker News

JavaScript Conquered the Web, Now It’s Taking Over the Desktop

wired.com

181–190 of 270 posts

Re: JavaScript Conquered the Web, Now It’s Taking Over the Desktop

#181
post #131
post #64

Earlier quoted context omitted.

> "Full-native development unique on each platform is considered too much effort, when you can get a cross-platform app with Electron" Yes, it's this. Full native development is awful since every platform is completely different, and other cross-platform solutions like Qt are a bit behind the web in terms of modern look and feel and developer base. But Electron is also awful, since a hello world app uses 100mb of RAM…

"But Electron is also awful, since a hello world app uses 100mb of RAM." Is it that awful, though? Most computers come with 4-16GB of RAM.

Yes, that is not just terrible it is embarrassing.

Re: JavaScript Conquered the Web, Now It’s Taking Over the Desktop

#182
post #23
post #13

JavaScript didn't "conquer" anything. It was just one of the first languages around when the web was still in its infancy, and simply never went away.

Lets be honest here, Javascript (alternately known as ECMAscript [1]) has done the following: a) progressively adopted new language features like prototypes, closures, generics and the like. Javascript just being there early wasn't enough. I has improved remarkably over the past 20 years, and the ECMA standards body has been critical to that improvement. That said, it's still a quirky language and that alone makes a…

> Lets be honest here, Javascript (alternately known as ECMAscript [1]) has done the following: a) progressively adopted new language features like prototypes, closures, generics and the like.

JavaScript had prototypes and closures from the beginning, no? Does it really have generics — a quick Googling makes it appear that it's a matter of hand-rolling. But it's been awhile since I've written JavaScript in anger, so perhaps I've missed an announcement since then.

Re: JavaScript Conquered the Web, Now It’s Taking Over the Desktop

#183
post #175

Earlier quoted context omitted.

I can't believe this is the top comment. Let's go point by point: 1) JavaScript has its warts and its gotchas like anything else (okay, maybe a few more). So what? Spend 50 hours building anything substantial with JavaScript and you'll get a good handle on them, and you'll be good to go for the next 10,000 hours. Same goes for just about any other language. Focusing on the weird edge cases might make for a nice blog…

> Spend 50 hours building anything substantial with JavaScript and you'll get a good handle on them, and you'll be good to go for the next 10,000 hours. Spending 10,000 hours building things with JavaScript sounds like a pretty good definition of Hell. JavaScript is an actively, abusively bad language. It's not that it has a few warts: it's nothing but warts. Its fundamental design flaws are obscured only by its supe…

In case Eich reads your comment: given that it had to be done in ten days and "look like Java", JavaScript is a fine langauge.

(But yeah, compared to languages that were designed over years obviously it's incredibly bad.)

To quote Eich (from here[1]):

" Ten days to implement the lexer, parser, bytecode emitter (which I folded into the parser; required some code buffering to reorder things like the for(;;) loop head parts and body), interpreter, built-in classes, and decompiler. I had help only for jsdate.c, from Ken Smith of Netscape (who, per our over-optimistic agreement, cloned java.util.Date -- Y2K bugs and all! Gosling...).

Sorry, not enough time for me to analyze tail position (using an attribute grammar approach: http://wiki.ecmascript.org/doku.php?id=strawman:proper_tail_...). Ten days without much sleep to build JS from scratch, "make it look like Java" (I made it look like C), and smuggle in its saving graces: first class functions (closures came later but were part of the plan), Self-ish prototypes (one per instance, not many as in Self).

I'll do better in the next life. "

[1] Edit: jwz.org intercepts HN links. See mjgoeke's comment.

Re: JavaScript Conquered the Web, Now It’s Taking Over the Desktop

#184

Earlier quoted context omitted.

What makes JS more "hackable"? Someone find that cartoon about the gaunt-looking guy and the laid-back kid when the girl asks them to hold her coffee and link it [edit: http://i.imgur.com/76Wtthy.jpg ]. ...Because it gets the hell out of they way and holds your coffee for you and doesn't slap it out of your hand and throw a tantrum because it was actually a medium coffee ...and it gives you the simplest no-BS object/…

Hmm not convinced. Is it pleasant UX that you can put petrol in your diesel car because the nozzle fits? Would it be pleasant UX to have your bank let someone withdraw money from your account without ID? Bleach bottle with no safety cap? Also the laid back kid of JS will throw a tantrum if the coffee is not a coffee. He'll throw the tantrum at your customer though (at runtime), not your developer (at compiler time).…

It would be pleasant if your engine didn't care whether you put gas or diesel in it and just ran. I think that's the point made in the cartoon.

I like that the kid just holds the cup and pours it when I tell him to. If I wanted him to pour coffee and gave him a cup of beer, I'm ok saying that's my fault. I'd still rather have the kid. Having a guy that only accepts "Large cups of coffee" is necessary at lower levels (c), but keep it out of my scripting language.

Re: JavaScript Conquered the Web, Now It’s Taking Over the Desktop

#185

> It turns out it’s useful to have a lingua franca for the web. No, I don't think so. Most people do not use JavaScript since it is useful. They use it since it is the only option available on the browser. There is a BIG difference. > Creating desktop apps in JavaScript lets developers choose from a vast range of freely available code libraries and frameworks, which takes much of the grunt work out of coding Lots of…

I've spend a decade in c and c++, another in Java. I've now moved to Javascript and I love everything about it. Well not everything, I don't really like the whole NPM and millions of dependencies. I also don't like react and angular. But JS is so big, there's enough other stuff I do like.

You see, you don't have to like everything about it to enjoy working with it. I pick the stuff I care about and put my positive energy towards it, instead of my negative energy towards the other. You should try it. You're free to make whatever tools you use right now as easy to use and as quick to learn. Maybe if you try hard enough, us Javascripters might come join your side.

Re: JavaScript Conquered the Web, Now It’s Taking Over the Desktop

#186
post #175

Earlier quoted context omitted.

I can't believe this is the top comment. Let's go point by point: 1) JavaScript has its warts and its gotchas like anything else (okay, maybe a few more). So what? Spend 50 hours building anything substantial with JavaScript and you'll get a good handle on them, and you'll be good to go for the next 10,000 hours. Same goes for just about any other language. Focusing on the weird edge cases might make for a nice blog…

> Spend 50 hours building anything substantial with JavaScript and you'll get a good handle on them, and you'll be good to go for the next 10,000 hours. Spending 10,000 hours building things with JavaScript sounds like a pretty good definition of Hell. JavaScript is an actively, abusively bad language. It's not that it has a few warts: it's nothing but warts. Its fundamental design flaws are obscured only by its supe…

> The ecosystem is terrible and the community is full of self-righteous assholes who has the collective attention span of a 2 year old

> I don't think he 'stooped' to anything

Really? This is supposed to be a place for civil, mature discussion. There are plenty of valid arguments against javascript as a language and as a community, there's no need for childish comments like that.

Re: JavaScript Conquered the Web, Now It’s Taking Over the Desktop

#187
post #150

Earlier quoted context omitted.

When I first started learning JavaScript, I wondered how people became proficient at the langue with all these weird quirks[0] that don't raise errors. Turns out that there are a bevy of things to help combat these quirks. Two of them are strict mode[1] (which can be scoped[2] in instances were libraries/frameworks would fail running in strict mode) and linters. Strict mode and linters do not fix everything. This is…

> I wondered how people became proficient at the langue with all these weird quirks[0] (links the usual loose equality table) Why don't you all just use === instead of ==? Tell me, how long does it take to learn it?

I think I have used weak equality once, because I needed truthy/falsy. I've always used strong equality. I always tell people that unless there is an absolute need for weak equality and you can thoroughly explain why weak equality works better than another solution, refactor for strong equality.

The all these weird quirks thing was really a naive me talking back then. JS was my second language after Java. Anonymous functions, async execution, implicit typing, weak typing - it requires a different way of thinking when you move from Java to JS and you're just starting. Most everything is explicitly defined, and everything executes in the order that is listed in Java. JS is whole different beast.

Re: JavaScript Conquered the Web, Now It’s Taking Over the Desktop

#188
post #180

Earlier quoted context omitted.

What makes JS more "hackable"? Someone find that cartoon about the gaunt-looking guy and the laid-back kid when the girl asks them to hold her coffee and link it [edit: http://i.imgur.com/76Wtthy.jpg ]. ...Because it gets the hell out of they way and holds your coffee for you and doesn't slap it out of your hand and throw a tantrum because it was actually a medium coffee ...and it gives you the simplest no-BS object/…

> it gives you the simplest no-BS object/array literals you can get I really don't think that: { "foo": "bar", "baz": ["quux", 1, true] } is simpler than: ((foo bar) (baz (quux 1 true))) Quite the opposite, really.

That does look nice. Is that, LISP? To my eye, they look roughly equivalent, though - and a lot of what I consider the "No-BS object system" occurs after the literal is declared - adding and manipulating properties, etc.

Re: JavaScript Conquered the Web, Now It’s Taking Over the Desktop

#189

> It turns out it’s useful to have a lingua franca for the web. No, I don't think so. Most people do not use JavaScript since it is useful. They use it since it is the only option available on the browser. There is a BIG difference. > Creating desktop apps in JavaScript lets developers choose from a vast range of freely available code libraries and frameworks, which takes much of the grunt work out of coding Lots of…

> > It turns out it’s useful to have a lingua franca for the web.

> No, I don't think so. Most people do not use JavaScript since it is useful. They use it since it is the only option available on the browser.

Are you not contradicting yourself here? If people use JS only because it's what's on the browser, then it's only because people see value in ... having a lingua franca for the web.

Re: JavaScript Conquered the Web, Now It’s Taking Over the Desktop

#190
post #175

Earlier quoted context omitted.

> Spend 50 hours building anything substantial with JavaScript and you'll get a good handle on them, and you'll be good to go for the next 10,000 hours. Spending 10,000 hours building things with JavaScript sounds like a pretty good definition of Hell. JavaScript is an actively, abusively bad language. It's not that it has a few warts: it's nothing but warts. Its fundamental design flaws are obscured only by its supe…

In case Eich reads your comment: given that it had to be done in ten days and "look like Java", JavaScript is a fine langauge. (But yeah, compared to languages that were designed over years obviously it's incredibly bad.) To quote Eich (from here[1]): " Ten days to implement the lexer, parser, bytecode emitter (which I folded into the parser; required some code buffering to reorder things like the for(;;) loop head p…

I'd recommend copy+pasting the link to www.jwz.org if you want to open it...

  https://www.jwz.org/blog/2010/10/every-day-i-learn-something-new-and-stupid/#comment-1048
Post reply on HN