This release adds the ability to use an alias prefix when using the bundler, making it possible to use your own custom data-*-*
attributes. It also changes how plugins are applied and cleaned up to use MutationObserver
, which is more efficient and allowed us to solve some timing issues with debouncing and intervals.
We had uptick in community PRs for this release, and a big push in terms of SDKs, so a big thank you to everyone who contributed 🚀
Added
- Added the ability to use an alias prefix when using the bundler. This makes it possible to use
data-customPrefix-*
attributes instead ofdata-*
.
Changed
- Changed the
data-on-interval
attribute to accept a__duration
modifier instead of a__delay
modifier (#513). - The
data-custom-validity
attribute can now be used onselect
andtextarea
elements, in addition toinput
elements (534). - Changed how plugins are applied and cleaned up to use
MutationObserver
(#528). - Changed the parsing of Datastar expressions so that only semicolons can be used to explicitly indicate a statement delimiter (#525).
Fixed
- Fixed a bug when using the
__delay
modifier on thedata-on-load
attribute (#511). - Fixed how Datastar expressions are evaluated to allow regular expressions and strings that contain semicolons and new lines (#508).
- Fixed a bug with the
inner
merge mode that was causing only the inner HTML of a fragment to be merged (#524). - Fixed a bug in which signal values could get out of sync when populated by an input element by Chrome’s back/forward cache (#530).
- Fixed a bug when generating IDs for elements that could result in duplicate IDs (#533).