Abstract
Access to current Alpine data.
Dispatch browser events.
the event name
Optional
data: anyan event-dependent value associated with the event, the value is then available to the handler using the CustomEvent.detail property
Retrieve the current DOM node.
Generate an element's ID and ensure that it won't conflict with other IDs of the same name on the same page.
the name of the id
Optional
key: string | numbersuffix on the end of the generated ID, usually helpful for the purpose of identifying id in a loop
Execute a given expression AFTER Alpine has made its reactive DOM updates.
Optional
callback: (() => void)a callback that will be fired after Alpine finishes updating the DOM
Retrieve DOM elements marked with x-ref inside the component.
Access registered global Alpine stores.
Fire the given callback when the value in the property is changed.
the component property
a callback that will fire when a given property is changed
Protected
bindingProtected
Declare an object as an x-bind property for this component.
Use this method to define properties for use with x-bind:
protected myBinding = this.binding({
["@click.prevent"]() { console.log("click prevented!") }
});
Define accessible properties (protected/private)
that are not included by keyof
The object for use with x-bind
The same object passed to obj
Generated using TypeDoc v0.25.1
Light-weight interface for class based components.
Provides property declarations for Alpine magics that will exist when used as an Alpine component.
Property declarations copied from @types/alpinejs.
https://www.npmjs.com/package/@types/alpinejs