JQuery

JQuery is supported by providing the classes JQueryAttributes, JQueryAttributesFactory and JQueryLibrary.These classes provide convenience methods for attributes to build pages that use JQuery and JQuery Mobile construts.

html
    .render(DocType.HTML5)
    .html()
        .head()
            .title().content("renderSnake - Mobile")
            .render(JQueryLibrary.mobileTheme("1.0a3"))
            .render(JQueryLibrary.core("1.4.4"))
            .render(JQueryLibrary.mobile("1.0a3"))
        ._head()
    .body()
        .div(dataRole("page"))
            .div(dataRole("header").dataTheme("b"))
                .render(new PageHeader())
                ._div()
            .div(dataRole("content").dataTheme("b"))
                .render(new HomePageContent())
                ._div()
            .div(dataRole("footer").dataTheme("b"))
                .render(new PageFooter())
                ._div()
        ._div()
    ._body()
    ._html();

To use these static methods (dataRole,dataTheme,...) you must import the following:

import static org.rendersnake.ext.jquery.JQueryAttributesFactory.*;

jQuery Mobile - Minimal

minimal mobile page

jQuery Mobile - Widgets

jQuery Mobile widgets