Results 1 to 12 of 12
  1.    #1  
    Ok,
    so i have the Mojo SDK, Eclipse. Now what do I need to learn to program some cool apps...is it Java or javascript to learn. I'm a fast learner, so whichever it is I'd like to know so that I can get started on some of my ideas for apps for the Pre.
  2. #2  
    JavaScript!

    You shouldn't have asked this question. You're going to get 5 billion responses on how Java is not JavaScript.

    I pray for you.
  3. #3  
    Yep, definitely Javascript. If you need a good book, i suggest: "Javascript: The Good Parts."
    Developer of:

    -------------------------------------
    Discuss my apps in my developer forum
  4. #4  
    If you don't mind spending alittle money, I would suggest getting an online course. This way you will have a strong core on javascipt and will make it much easier to write in it, without having to look back in your book over and over.
    "Life is Hard... it's harder if your stupid"
    - John Wayne
  5. SDash's Avatar
    Posts
    256 Posts
    Global Posts
    260 Global Posts
    #5  
    w3schools.com is a good start for a tutorial
  6. #6  
    GOOOOOGLE some Javascript tutorials. Uninstall the eclipse that takes lightyears to start up, install notepad++, start throwing ****** at the wall and see if it sticks. If you don't even know what javascript is then i think you should first install apache and start by learning how to build some websites on your apache setup. Beleive dat. IMHO you should just forget developing for the pre for now. WHERE IS THE EFFIN NEWBIE CORNER precentral?
  7. chimeric's Avatar
    Posts
    69 Posts
    Global Posts
    71 Global Posts
    #7  
    Wow nohatter. Pretty impressive response. Please tell us all of your glorious contributions to the world of Javascript so that we may bask in your programming genius.
  8. #8  
    Quote Originally Posted by nohatter View Post
    GOOOOOGLE some Javascript tutorials. Uninstall the eclipse that takes lightyears to start up, install notepad++, start throwing ****** at the wall and see if it sticks. If you don't even know what javascript is then i think you should first install apache and start by learning how to build some websites on your apache setup. Beleive dat. IMHO you should just forget developing for the pre for now. WHERE IS THE EFFIN NEWBIE CORNER precentral?
    installing apache makes no sense. to learn javascript all you need is a browser and txt editor.
  9. yiffzer's Avatar
    Posts
    218 Posts
    Global Posts
    232 Global Posts
    #9  
    But his point still remains: it is good learning by throwing crap on the wall and seeing what sticks. In other words, manipulating already produced code and seeing what the results would be. Setting up your own web server is a nice thing too but perhaps unnecessary.
  10. nhavar's Avatar
    Posts
    285 Posts
    Global Posts
    293 Global Posts
    #10  
    Quote Originally Posted by srlake314 View Post
    Ok,
    so i have the Mojo SDK, Eclipse. Now what do I need to learn to program some cool apps...is it Java or javascript to learn. I'm a fast learner, so whichever it is I'd like to know so that I can get started on some of my ideas for apps for the Pre.
    Go to the Palm Developer website Welcome to webOSdev - Palm and start with the setup and tutorial there. Get the SDK, Aptana, and then the Palm plugin for eclipse. Aptana is a good IDE to start out with because it has built in "intellisense" and is based off of Eclipse so it will get you familiar with developing in that environment. It has the capability to create your whole app template for you as well as just hitting a single button to push your app to the emulator for testing.

    You can start with the Palm tutorials and the emulator and just throw some stuff together to see what sticks. However, you'll do better if you learn the basics of JavaScript first. Douglas Crockford's book is a great resource.

    Things that are important to cover:
    • Functions, variables, objects, and scope
    • Closures
    • this (goes along objects and scope)
    • DOM manipulation
    • Arrays


    for example:

    function myFunction(){}
    var myFunction = function(){};
    myObject.prototype.myFunction = function(){};
    var myObject = {myFunction:function(){}};

    Are all ways of expressing a function and you will see code that uses all of those examples to different purposes.

    There are also some sites that can give you guidance on best practices. Things like:

    End your lines with a semicolon, declare your variables in scope using var, never omit curly braces. And then there are some speed tips as well like this one on for loops

    for(var i = 0, iLen = myArray.length; i < iLen; i++){
    /*do something here*/
    }

    If you cache the length of the array it takes less time to test against it and speeds up the loop.

    There's tons to learn and plenty of tutorials and books out there. Most of all find projects to try out that are small and fun.
  11. nhavar's Avatar
    Posts
    285 Posts
    Global Posts
    293 Global Posts
    #11  
    Quote Originally Posted by yiffzer View Post
    But his point still remains: it is good learning by throwing crap on the wall and seeing what sticks. In other words, manipulating already produced code and seeing what the results would be. Setting up your own web server is a nice thing too but perhaps unnecessary.
    Yeah setting up a webserver isn't necessary to start with. Just about everything can be loaded in the web browser off of the filesystem or previewed in Aptana or in the emulator.
  12.    #12  
    Thank you all, I appreciate any and all help. Everyone has their preferences for programs, and that is obvious with all the different "HOW TO" links out there. That is what can cause some confusion, even like the NEXT STEPS webos optware andsuch, it mentions putty, which I cannot get to work for the life of me(Pre port 222, emulate 5522), so forth and so on. I was just trying to get the simple code that I found on that same website, following THEIR destructions and to no avail, just fewer hairs now .

Posting Permissions