Want to read Slashdot from your mobile device? Point it at m.slashdot.org and keep reading!


Forgot your password?

Submission + - Making JavaScript Tolerable for A Dyed-in-the-Wool C/C++/Java Guy 6

DocDyson writes: I'm a dyed-in-the-wool C/C++/Java developer with over 20 years of experience. I'm making a good living and having fun doing back-end Java work right now, but I strongly believe in being a generalist, so I'm finally trying to learn the HTML5/CSS3/JavaScript future of the Web. However, I find JavaScript's weak typing and dynamic nature difficult to adapt to because I'm so used to strongly-typed, compiled languages with lots of compile-time error-checking and help from the IDE. Does anyone out there who has made this transition have any tips in terms of the best tools and libraries to use to make JavaScript more palatable to us old-school developers?
This discussion was created for logged-in users only, but now has been archived. No new comments can be posted.

Making JavaScript Tolerable for A Dyed-in-the-Wool C/C++/Java Guy

Comments Filter:
  • Do look into Dart from Google.

    In some ways it hearkens back to RatFOR
    and even the early C++.

    The Dart compiler can emit JS and can
    be used to add type checking and other
    structure. It is a little early but it has
    big value in a largish programming staff because
    changes in one file can be inspected by the
    Dart compiler which can discover errors that
    result from uncoordinated changes in variables
    functions, objects etc...

  • If you "strongly believe in being a generalist", then you should learn the inherent nature of dynamic and loosely-typed languages rather than trying to fit them into your existing knowledge. I have a similar background to yours but managed to master most of Javascript. You can do it, too. Have patience and use learn jQuery -- you won't regret it.
    • I am using jQuery (and jQuery UI) on my first "real" project with these new technologies (a Web-based demo for some back-end technology I developed). What do you recommend in terms of an IDE on either the Mac or Linux platforms?
      • Believe it or not, I use gedit when on my linux box. It provides keyword coloring, line numbers, brace/parenthesis matching, and even shows you when an HTML tag isn't closed. I then save and Ctrl+R on the browser to see changes. That's enough for me, but since you are still in the early phases of learning, you might want more. Give Eclipse Web Tools Platform a try (F/OSS). It does all of the above plus things like highlighting of Javascript syntax errors.

        Learn Firebug inside and out. It's got a JS debugger

  • Someone famously showed on their webpage how a simple Hello World program in Dart "compiled" to 17,000 lines of code.

    I would give CoffeeScript a go. It's easy to find on the 'net. And it works with jquery.
  • I too am a C programmer (embedded) who is learning web programming. I liken C programming to weaving fabric (a program) out of a single type of yarn (c language). Web programming is like making your own yarn out of HTML, CSS, JavaScript/PHP/whatever, then weaving it into the fabric. It's taking some getting used to. I've been searching online for free tutorials and getting books at my local library, which has some recent good additions. I have the luxury of a wife who knows nothing about internet technology

What is algebra, exactly? Is it one of those three-cornered things? -- J.M. Barrie