Welcome to the jsUI wiki!
Install via NPM:
npm i javascript-ui
At the base of jsUI is its element abstraction built on top of the JavaScript DOM abstraction.
Import and use the view() function to start.
view()
import {view} from 'javascript-ui'; view([ // nest elements... ]);
Import and use built-in elements based on standard HTML tags:
import {view, Section, Paragraph} from 'javascript-ui'; view([ Section([ Paragraph("Text") ]) ]);
This results in the following HTML being added to the body:
<section> <p>Text</p> </section>
To add style, events, etc. you chain methods onto the element function.
import {view, Paragraph} from 'javascript-ui'; view([ Paragraph("Text") .textColor("green") ]);
Resulting in:
<p style="color: green">Text</p>
There was an error while loading. Please reload this page.