DEV Community

Discussion on: Toast Notifications with Alpine.js & Tailwind.css

Collapse
 
kerns profile image
David Kerns

Zack this is such a great resource, together with all the other tailwind+alpine examples in your repo. Really nice.

It would be nice if there was a little more context as to why we need Spruce, but maybe it will become more clear as I dig in. :)

Collapse
 
zaxwebs profile image
Zack Webster • Edited

Thank you for your words, David.

About Spruce, I have it for this as I'd like the ability to invoke the toasts from anywhere. So, a global state management solution seemed like a good idea.

Collapse
 
kerns profile image
David Kerns

My understanding is this is a core part of Alpine 3. So maybe this and other examples you’ve made could see Spruce being phased out. 🤔☺️

Thread Thread
 
zaxwebs profile image
Zack Webster

Alpine 3 came out about 3 months after this post.
But yeah, if I were to redo these now, I'd definitely go with core.