Live data from Hacker News

The JavaScript Problem

haskell.org

11–20 of 183 posts

Re: The JavaScript Problem

#11
post #10

I've been trying to convince my workmates to try something other than pure JS (with Angular), but am not having much luck. TypeScript seems to have the most buy-in, but most of the guys in the office aren't convinced of the benefits of a proper type system, the just see it as more work for them for little upside. Any ideas?

What kind of office are you in? If it's filled with a lot of front-end JavaScript "ninjas" I doubt you're going to make much headway. I hate to be pejorative, but I do mean the ninja part pejoratively.

My best advice would be to try to start by convincing the guys with the most dev experience in other languages/serious dev experience/(dare I be controversial and say )guys with the most formal CS education first.

Re: The JavaScript Problem

#13
post #10

I've been trying to convince my workmates to try something other than pure JS (with Angular), but am not having much luck. TypeScript seems to have the most buy-in, but most of the guys in the office aren't convinced of the benefits of a proper type system, the just see it as more work for them for little upside. Any ideas?

Is it that they don't properly understand the benefits of switching on their productivity, or that they just don't think the productivity gain will be large enough to justify the switch?

If it's the former, then yeah, a logical explanation might help, but the latter seems a bit more subjective, and it's possible they just see their current workflow as completely adequate. Quantifying productivity gains is tricky, and the "if it ain't broke, don't fix it" philosophy has some merit.

Re: The JavaScript Problem

#14
I take issue with the paragraph about how Javascript sucks:

* Javascript is actually untyped, not weakly typed (untyped means no type declarations, not that it has no types) and I don't see that as a problem.

* Being an entirely interpreted language, JS cannot have static type checking. This has not been an issue in my experience.

* I think the syntax argument is laughably ridiculous. Programming languages that live in glass houses shouldn't throw stones. Just today, I've seen three links to guides "to learn basic Haskell syntax", two of which contradicted each other.

* I agree with their statement on `this` behavior. This (pardon my pun) is one of the places where JS's well-intentioned DOM-manipulation features cause problems with it as a language.

Re: The JavaScript Problem

#15
post #6

Pretty strange to mention TypeScript and not Dart... which solves a lot of his criticisms and is arguably more popular. I respect the functional guys a great deal but the use of Haskell for front-end dev is realistically going to only be an interesting option for those already using it for the backend. It has nothing to do with the merits of the solution and everything to do with people's comfort zones.

The page is about JS. TS is a superset of JS, and Dart is an entirely different language.

It mentions Coffeescript.

Re: The JavaScript Problem

#16

I take issue with the paragraph about how Javascript sucks: * Javascript is actually untyped, not weakly typed (untyped means no type declarations, not that it has no types) and I don't see that as a problem. * Being an entirely interpreted language, JS cannot have static type checking. This has not been an issue in my experience. * I think the syntax argument is laughably ridiculous. Programming languages that live…

[deleted]

Re: The JavaScript Problem

#18

I take issue with the paragraph about how Javascript sucks: * Javascript is actually untyped, not weakly typed (untyped means no type declarations, not that it has no types) and I don't see that as a problem. * Being an entirely interpreted language, JS cannot have static type checking. This has not been an issue in my experience. * I think the syntax argument is laughably ridiculous. Programming languages that live…

> untyped means no type declarations, not that it has no types

I found this to be a very bizarre statement, given the existence of dynamic typing. For anyone else confused, this is the best discussion I could find of the issue:

http://stackoverflow.com/questions/9154388/does-untyped-also...

Re: The JavaScript Problem

#19

I take issue with the paragraph about how Javascript sucks: * Javascript is actually untyped, not weakly typed (untyped means no type declarations, not that it has no types) and I don't see that as a problem. * Being an entirely interpreted language, JS cannot have static type checking. This has not been an issue in my experience. * I think the syntax argument is laughably ridiculous. Programming languages that live…

* Being an entirely interpreted language, JS cannot have static type checking. This has not been an issue in my experience.

This doesn't mean it isn't an issue, just you haven't encountered a situation where it is.

* I think the syntax argument is laughably ridiculous. Programming languages that live in glass houses shouldn't throw stones. Just today, I've seen three links to guides "to learn basic Haskell syntax", two of which contradicted each other.

And you've never seen three guides to "learn basic Javascript syntax" which contradict each other?

You can argue it both ways, as far as I am concerned. Javascript like any other language has issues, what exactly those issues are... depends greatly on what you use Javascript for.

Re: The JavaScript Problem

#20
post #18

I take issue with the paragraph about how Javascript sucks: * Javascript is actually untyped, not weakly typed (untyped means no type declarations, not that it has no types) and I don't see that as a problem. * Being an entirely interpreted language, JS cannot have static type checking. This has not been an issue in my experience. * I think the syntax argument is laughably ridiculous. Programming languages that live…

> untyped means no type declarations, not that it has no types I found this to be a very bizarre statement, given the existence of dynamic typing. For anyone else confused, this is the best discussion I could find of the issue: http://stackoverflow.com/questions/9154388/does-untyped-also...

There seem to be a few different viewpoints on the matter. This is the one I go with (as well as Brendan Eich and other high-profile JS people.)
Post reply on HN