Hacker News new | ask | show | jobs
by toretore 5724 days ago
TL;DR: I don't actually understand how JavaScript works, but I thought writing a nonsense article demonstrating my willingness to bash it nonetheless with an aggressive headline and post it on HN myself would bring me some desperately needed attention.
2 comments

If I do or do not know Javascript is actually tangential to my point. What I find strange is that the browser environment forces a language on developers and that is seen as OK. When apple was adding language/framework restrictions to the AppStore people were screaming bloody murder but somehow the browser status quo is fine.

That being said the title was probably too agressive. The original was not very descriptive and it was what I came up with on the spot.

The AppStore restrictions are top-down decisions for commercial reasons.

Whereas the web ecosystem has evolved this way.

You can write code that compiles to bytecode to run on a browser -- applets, Flash, Silverlight -- but for various evolutionary reasons, none of them have become dominant over JS.

It's like being cross about how few air-breathing fish there are, and writing to HN to complain.

>The AppStore restrictions are top-down decisions for commercial reasons. >Whereas the web ecosystem has evolved this way. >It's like being cross about how few air-breathing fish there are, and writing to HN to complain.

It was a rant about how things turned out. I'm not expecting anyone to go out and build something I'd like better. But it does surprise that most people think it's OK that an increasingly more important environment is limited to a single language. I was attacking Javascript as a single choice more than Javascript as a language, but I should have probably have made that more explicit as there were plenty of comments about how this was just me not knowing enough Javascript.

>You can write code that compiles to bytecode to run on a browser -- applets, Flash, Silverlight -- but for various evolutionary reasons, none of them have become dominant over JS.

All of those are ways to run code inside a box inside a webpage. None really replace Javascript as a DOM manipulator with a bytecode. I don't think there has ever been any portable option besides Javascript (or emitting Javascript from something else) to do scripting on a page that isn't constrained inside Flash/Applet.

I do see what you mean about the lack of choice, although I'd rather have all browsers implement one language consistently and and well, rather than a number of languages flakily and non-universally.

The compiling-to-JS idea has a lot of potential I reckon. I've done a couple of GWT projects and the results work very well, much better than if I'd written the JS myself, and not noticeably slow. And debugging the app in Eclipse is so much nicer than using a JS debugger.

Unkind my friend. I think the OP is looking for encouragement and enlightenment. Perhaps you could share some thoughts on how you tackle these issues.
The OP deliberately wrote a rant about something he doesn't understand with an attention-grabbing headline and I called him out on it. I don't think that's unkind. I would have assumed good faith were it not for him explicitly stating he actually doesn't want to learn JavaScript but still wants to bash it.
You seem to be focusing of if I know Javascript or not. I don't know enough and I am learning. So it's not that I don't care. It's that I don't understand why Javascript being the only option on the client side is OK somehow. I've changed the title to be less aggressive.