You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hey @gap777, thanks for opening this issue and for proposing to upstream your useMapReduce function!
Currently stimulus-use is more a collection of behaviour/callbacks-related use-functions. But I really love the idea of extending it to more smaller use-utilities which can be commonly used in Stimulus controllers, like your useMapReduce.
I would love to see how that implementation might look like. Do you want to take a stab at it? Let me know if you need any help or have questions along the way!
A few of our stimulus controllers ended up having a very similar structure:
Examples:
aria-invalid
attribute setWe've come up with a way to significantly reduce the boiler plate of these using a map-reduce mixin:
each of configuration items is a callback function.
Used like this:
We're willing to share it with others, and wondering if you want it to be a part of your
stimulus-use
library.The text was updated successfully, but these errors were encountered: