welp, htmx is bloat
(minified ~270 B)
a little hypermedia framework that is super tiny and very simple to use no bs.
just copy the contents from https://raw.githubusercontent.com/vilgacx/aki/main/index.min.js
and then use it as aki.js
curl https://raw.githubusercontent.com/vilgacx/aki/main/index.min.js > aki.js
<script src="<path>/aki.js"></script>
(that's it)
pick any element that you wanna make aki-ed and add two attributes: url
(the GET url) and fn
(the type of function on which things will implemented [for e.g.: onclick, onfocus]).
<h1>hello world</h1>
<button url="http://.../<get-method-url>" fn="onclick">click</button>
{
"element-selector-1": {
"property-1-1": "value-1-1",
"property-1-m": "value-1-m"
},
"element-selector-n": {
"property-n-1": "value-n-1",
"property-n-i": "value-n-i"
}
}
{
"h1": {
"style": "color:navy;",
"innerText": "you have been aki-ed"
},
}
aki is released under the BSD-2-Clause License. See the LICENSE file for more information.