Categorized | Code, Development

Hell-o world WebOS

Building native apps in HTML/Javascript and CSS. The idea is good, and it just might some day rid us of the programming language fragmentation…. Some day…

But not quite yet. Not in my opinion anyhow, after giving WebOS from Palm a try.  My previous experience with HTML/Javascript/CSS based native apps was by using PhoneGap in an iPhone application, that actually works the way I expected, with the “look and feel” of how i would create any other ordinary web/html application.  With WebOS and the Palm WebOS SDK there’s a different way to do it….

[Update: This post relates to WebOS release 1.4.x]

Firstly, you download and install the SDK and the VirtualBox WebOS emulator. To start a new project you fire up a command prompt or terminal window and type the generate command:

> palm-generate -p “{title:’Hello World’, id:com.mystuff.hello, version:’1.0.0′}” HelloWorld

This generates the basic application folder structure for you with the first “ViewController” called index.html. Then you need to create a View, or a Scene as they call it. (which actually is saved in a folder called views…..) The view is created yet again with the magic palm-generate command at command line.

> palm-generate -t new_scene -p “name:first” HelloWorld

The application run from the emulator should look like this.

You now have a html file called “/app/views/first/first-scene.html”. This is where you place the content of that view/scene.  The content could look like this…

<div id="main">
     <div id="count">0</div>
     <div id="MyButton"

The ViewController (index.html) is controlled from ‘/app/assistants/stage-assistant.js’ (someone has been fond of the theatre here) and the View/Scene is controlled by ‘/app/assistants/first-assistant.js’

You get your mojo going by hooking the button click event inside ‘first-assistant.js’ and you configure the View/Scene in the setup method.

Ahh.. I phased out… too much code to many places to get a simple button push count app….. If i’d been using Eclipse i could have avoided the trips out to the command line, but I’m not much of a Eclipse fan, and as web/html development it’s too bound to the WebOS platform for me.

Want to try for yourself you can find the complete guide here at Palm Developer Center.

Use Facebook to Comment on this Post

One Response to “Hell-o world WebOS”


  1. […] as an operating system on smartphones and tablets from the first time I saw it, and tried it (see the hell-o world […]

Leave a Reply

Google Translate


Blog Traffic


Pages|Hits |Unique

  • Last 24 hours: 1,915
  • Last 7 days: 13,626
  • Last 30 days: 64,152
  • Online now: 5

Enter your email address to subscribe to this blog and receive notifications of new posts by email.

%d bloggers like this: