top | item 7722063

(no title)

grifpete | 11 years ago

Learning to program in Javascript is like programming in assembler. That may be unavoidable when there are no high level languages, or when those languages and toolsets are immature. But there are serious experts (and people with a lot of experience with very large js programs) who don't see js as the solution. "Goaded by Meijer as to whether it is possible to write big programs in JavaScript, Hejlsberg replied, €œYes, you can, but you can€™t maintain them," much to the delight of the crowd that featured several prominent language and tools designers. €œI think there are some unmet needs there,€ Hejlsberg added. Bracha immediately piped in saying, €œThat€™s part of why we€™re doing Dart. You can write them [large programs in JavaScript]; it€™s terribly hard and afterward you€™ll be punished.€ - See more at: http://www.eweek.com/c/a/Application-Development/Is-it-Time-...

discuss

order

camus2|11 years ago

> Yes, you can, but you can€™t maintain them

Well, i'd say it's more difficult but doable.(And i'm not a fan of javascript).

But tools are being created to help developpers maintain these "large apps".

Code analysis engines are the most important thing to work on in javascript land.I wish more people would work on that instead of framework MVC X or Y.

Something like TernJS ,while not perfect is actually doing interesting thing in term of understanding js code and auto completing it.

Now as I always say,dont like javascript? doesnt matter there are 100 languages you can use instead of it and still write for the web. The only thing that is important imho is wether that language can directly talk to the DOM or not,and invoke third party libraries.

that's why i'm not comfortable with Dart(but maybe it has changed).

I was trying alternative languages the other day and wrote this with one of them,the only thing i had to do to make it run in a browser is eval the transpiled version :

   (define $taskList ($ "#tasks"))
   (define $input ($ "input"))
   (define $form ($ "form"))
   ;; add task
   (define (addTask task)
   	(let ((t ($ "<li>" {"class" "task link"} )))
        (t.on "click" (lambda (event)
                       (t.toggleClass "stroke")))
   	(t.text task)))
   ;;on submit
   ($form.on "submit" (lambda (event)
       ($taskList.append (addTask ($input.val)))
       ($input.val "")
       (event.preventDefault)))
FYI this is the classic todo list with jQuery

There is no shame into writing for the web and not using javascript.At the end of the day,only the product matters.