A set of teeny-tiny libraries for building web apps.
The goal of this toolkit is minimal amount of concepts to learn, making the system incredibly easy to reason with, and comes in at a miniscule size when compressed.
<div id="app"></div>
<script type="module">
import { mount, node as n } from 'https://cdn.jsdelivr.net/npm/@doars/staark@1/dst/staark.js'
mount(
document.getElementById('app'),
(state) => n('div', [
n('div', 'List'),
n('ol', state.todos.map((todo) => n('li', todo))),
n('input', {
value: state.input,
input: (event) => state.input = event.target.value,
}),
n('button', {
click: () => {
if (state.input.trim()) {
state.todos.push(state.input.trim());
state.input = '';
}
},
}, 'Add')
]),
{ todos: ['Hello there.', 'General Kenobi.'], input: '' },
)
</script>Comes in at a tiny size.
Due to the minimal philosophy and simple concepts, the libraries are compressed to just a few kilobytes, with staark at 1.5kB.
Efficient diffing algorithms.
The node tree is morphed quickly from old to new with minimal overhead, ensuring fast updates.
Minimal amount of concepts to learn.
The system is incredibly easy to reason with because you only need to learn a few core functions to build web apps. Simply mount the app and create nodes with the node function, then change the state to update the app, There are more functions available, but these are all optional.
Easy to add to your project.
Explore the packages!
The staark toolkit includes multiple libraries for state management, networking, real-time synchronization, and more.
In the wild
See staark in action in these projects:
Toaln is a simple language learning app which utilises the power of Large Language Models to practise
Tools by Ron Dekker are a set of widgets whose functions range from colour conversion to text analysis.
Comparisons
Curious how staark compares to other libraries? Check out the performance comparisons for build size, runtime performance, and memory usage.