Titanium Community Questions & Answer Archive

We felt that 6+ years of knowledge should not die so this is the Titanium Community Questions & Answer Archive

What happened to HTML & CSS?

I'm playing around with the mobile 1.0 SDK…and I don't see any way to use HTML and CSS anymore. Now that our apps are 'native' does that mean we've got nothing but javascript and the APIs to make our apps? This seams like a huge change in direction, and while apps will be faster, they will certainly be uglier and more restrictive. I want to be able to use the new HTML5 canvas to draw custom charts etc. Anybody?

— asked March 9th 2010 by David Geddes
0 Comments

2 Answers

  • In most respects I think the change to JS is a good one but there has been one major issue for the apps that I have been working on. That's the loss of the more comprehensive support for XML in the WebView's JavaScript model. This uses the native browser JS APIs rather than the Titanium ones.
    The consequence for me is that I can no longer use XSLT, node iterators and TreeWalkers in my code.
    Regards
    Mark

    — answered March 9th 2010 by Mark Poston
    permalink
    0 Comments
  • Hey David,

    You can still use web view components in your 1.0 applications to do anything which requires the use of HTML or CSS. The difference is that in 1.0, web views are squarely focused on displaying and running web content. The new programming model allows native applications to be fully native and look and perform as such.

    I have to call shenanigans on the "ugly" and "restrictive" comments, though, since it is possible to create stunning native applications (we've seen several already) with fully native code. And since you have granular control over native views and components, PLUS full access to a web view and all the power therein, I would argue Titanium is even more flexible now than it was before.

    We hope you'll come to like the changes we've made, as they go a long way in improving the overall experience. We're also happy to help everyone as we make the transition.

    — answered March 9th 2010 by Kevin Whinnery
    permalink
    0 Comments
The ownership of individual contributions to this community generated content is retained by the authors of their contributions.
All trademarks remain the property of the respective owner.