We can't find the internet
Attempting to reconnect
Something went wrong!
Hang in there while we get back on track
export default {
unitName: "MoreOtters",
otterCount: 0,
makeOtter: function(){
this.el.insertAdjacentText('afterbegin', "🦦")
this.otterCount += 1
}
}
<div data-unit="MoreOtters">
<div class="btn" data-on="click->makeOtter">
Make an Otter!
</div>
</div>
//Then simply access the unit, and get or run what you need!
let otterEl = document.querySelector('[data-unit="MoreOtters"]')
let unit = otterEl._unit
let otters = unit.otterCount
Made to be simple but powerfull, we provide a small but strong basis for Single Page Applications, Progressive Web Apps and Ajax / Forms. Current status has Events, AJAX and SPA capabilites handled. PWA capabilites are being considered in the future, but not currently.