Slashdot Mirror


The Great JavaScript Debate: Improve It Or Kill It

snydeq writes "Recent announcements from Google and Intel appear to have JavaScript headed toward a crossroads, as Google seeks to replace the lingua franca of the client-side Web with Dart and Intel looks to extend it with River Trail. What seems clear, however, is that as 'developers continue to ask more and more of JavaScript, its limitations are thrown into sharp relief,' raising the question, 'Will the Web development community continue to work to make JavaScript a first-class development platform, despite its failings? Or will it take the "nuclear option" and abandon it for greener pastures? The answer seems to be a little of both.'"

13 of 482 comments (clear)

  1. How about neither? by Hatta · · Score: 4, Insightful

    Leave the web for documents. Run applications natively. Why is this so hard?

    --
    Give me Classic Slashdot or give me death!
    1. Re:How about neither? by hjf · · Score: 5, Informative

      Because Google needs you to run everything in their cloud so the NSA,FBI,CIA, and even the DMV can get easy access to all your documents.

    2. Re:How about neither? by smagruder · · Score: 4, Insightful

      Please keep the politics out. Can't we have a haven for tech-only discussion please?

      --
      Steve Magruder, Metro Foodist
    3. Re:How about neither? by theArtificial · · Score: 4, Insightful

      A SSH session uses about the same amount of bandwidth as it did in the 90's. Now you need a 3mbit pipe just to load an ordinary web page in a decent amount of time.

      You know what else uses the same bandwidth of the 90s? 90s webpages. The websites of today are doing more than ever (streaming video, multimedia rich) and file sizes and screen resolutions have increased. Compare the file size of the average game released today to that of 1999. Why don't you fire up Lynx and save yourself the aggravation?

      You imply that the delays are due to JavaScript yet majority of the data on the wire isn't JavaScript. The delays you're referring to are mostly due to DNS lookups (and subsequent downloads) of byte heavy multimedia like images, video, and other goodies like Flash and data. As sites have grown in complexity a bottleneck occurs with the number of HTTP requests which a browser may make. The CSS file is parsed and the assets are downloaded the user must wait. The wait may be reduced employing a thoughtful design and clever use of domains (and subdomains). CDN (Content Delivery Networks) are popular for this very reason. At the server level on-the-fly compression may be enabled for various mime types (JS, html pages, smaller images etc.) to increase speed even further without requiring application level changes.

      JavaScript may be used in many ways to improve performance on sites, for example: instead of downloading all the map data one only needs what's in the view port. Additionally images which a user never views may not be requested, saving bandwidth. Like any tool it can be misused. Sites which use several ad scripts, analytics, 3rd party widgets etc. are the exception. What about interactive sites (powered by cobbled together server side scripts, made with multiple frameworks) which operate in an underpowered, over provisioned VM, on a shitty pipe with oodles of other sites located on the other side of the world? JavaScript indeed. To see stuff done right look at Amazon.

      So with JavaScript gone you have Flash, video, and data. I'm sure these will all be faster now... (since we're using less of these now than in the 90s, right?)

      10 years ago new releases of MS Office bloatware was driving the PC upgrade cycle, now its Web Apps and ordinary websites that have been unnecessarily 'appified'

      You're leaving out a big one: entertainment, specifically games. In addition new technology such as DVD, Bluray, data interfaces (USB 3.0) factors in too. I however agree with you, plenty of sites are one trick ponies that in the days past would've been a small program are now a web 2.0 site... which will generate insults seemingly using as many technologies and 3rd party service mashups as possible.

      --
      Man blir trött av att gå och göra ingenting.
  2. JavaScript fulfills its mission pretty well by smagruder · · Score: 5, Insightful

    If someone wants to add to its mission, or write a client-side language with a different mission, go for it.

    But a lot of the web is running nicely with JavaScript, and pulling out the JavaScript rug from web developers and website owners is really not an option.

    Let's call for some pragmatism here, shall we?

    --
    Steve Magruder, Metro Foodist
  3. Re:In my opinion... by hjf · · Score: 4, Funny

    Why? This is not 1999. We don't "hate" javascript anymore, like we did years ago.

    Now we hate flash. Get on the wave, man.

  4. Mission creep. by PeanutButterBreath · · Score: 4, Funny

    I decided it would be a neat hack to flood my living room and turn it into an indoor pool. Boy, did that reveal some serious shortcomings in my home's electrical system. Can any recommend an electrician who doesn't suck as bad as the guy who installed the one I have now?

  5. Re:The unpopular vote by Microlith · · Score: 4, Insightful

    Soon as Microsoft surrenders language and library development to a 3rd party that operates in an open manner and allows any and all uses without royalty requirements.

    As it stands? No way. That's just handing Microsoft what they've always wanted.

  6. Re:In my opinion... by aztracker1 · · Score: 5, Insightful

    What you are talking about isn't the responsibility of the language, but the underlying API provided by the browser. And yes, there is some movement towards exposing those hardware elements to the JS API. Though not formally part of the DOM... The language itself is in my opinion a very elegant functional prototype based language. Though recent movements are to avoid use of the prototype aspects of the language.

    It seriously bugs me when people confuse the DOM/JS API for a given platform and the language itself. One is not intrinsically tied to the other. JS has been a favorite language of mine for a very long time (since around 1996). It gets a bad rep. mainly because of the browsers' DOM implementations in the v4 browser war... Don't hate the player, hate the game.

    --
    Michael J. Ryan - tracker1.info
  7. Static Strong by kervin · · Score: 4, Interesting

    Give us a static strongly typed alternative/extension without the literally hundreds of known design flaws.

    How about a Javascript that's more Java-like?

  8. Re:In my opinion... by chill · · Score: 4, Funny

    A beautiful rant killed by an ugly fact.

    --
    Learning HOW to think is more important than learning WHAT to think.
  9. How many times will we have this argument? by rabtech · · Score: 4, Insightful

    The history of the Internet and examples like IPv6, HTTP, SMTP, etc have shown us over and over that "good enough" + evolution trumps replace almost every time.

    The path forward is clear: improve JavaScript, extend it, improve HTML, and keep on trucking. Neither will ever be replaced on a wide scale, only evolved.

    The reason we don't already have worldwide IPv6 deployment is they redesigned IP instead of just extending the addresses.

    --
    Natural != (nontoxic || beneficial)
  10. Read Crockford's "Javascript: the good parts". by csirac · · Score: 4, Informative

    How does one establish whether methods/vars are public/private/protected? Or inheritance? To me, the weird misappropriation of the function keyword to build objects, the verbosity of the code to express objects, and the lack of inheritance, etc. are primitive compared to Actionscript 3, to Java, to PHP5, to C++, and a variety of other languages I've dealt with.

    You really need to read Crockford's "Javascript: the good parts". You absolutely do make private methods and vars (ever noticed that you can't directly call jQuery's internal methods? Or TinyMCE's? Or any other major library/framework?)

    He also makes the case that actually JS has more patterns to allow code re-use. That's why things like Mootools can even fake things that look like classical class inheritance patterns for you, if you really want to do that.

    Check out http://www.crockford.com/javascript/inheritance.html and http://javascript.crockford.com/prototypal.html and http://www.slideshare.net/douglascrockford/javascript-the-good-parts-3292746