Top
craft-uikit
craft-widget-

CraftKit

CraftKit is a JavaScript UI library for Clear Web OOP.

Try online tutorial:
https://github.com/craftkit/craftkit-playground)

Markup principle:

<Hello name="world"></Hello>

CraftKit:

viewController.appendView(new Hello({name:"world"}));

Mobile application devplopers are more familiar with this way.

console:

> var hello_world = new HelloWorld();
> hello_world.loadView();
> document.body.appendChild(hello_world.view);

> MyApp_HelloWorld_0
HelloWorld {packagename: "MyApp.HelloWorld", 
  componentId: "MyApp_HelloWorld_0", 
  view: div#MyApp_HelloWorld_0, css: Array(1), …}

> MyApp_HelloWorld_0.view
<div id="MyApp_HelloWorld_0">...</div>

> MyApp_HelloWorld_0.shadow
#shadow-root (open)

> MyApp_HelloWorld_0.root
<div class="root">...</div>

> MyApp_HelloWorld_0.css
[style#MyApp_HelloWorld_0_1]

> MyApp_HelloWorld_0.say()
(say() is invoked -> show "Hello World!" in the page)