Closed toverux closed 3 years ago
@toverux, this project will be continued and published?
I don't think so - or probably not in the coming months. Also, people don't seem to be much interested in it, so I don't want to add another project that would disperse SweetAlert2 collaborators too much for not much gain (this was destined to be imported into the sweetalert2 organization, like all the other official projects). That being said I liked the API and the core principles of it. Some day, maybe...
This new project and SweetAlert2 integration is born three days ago. This is a light (we can reach ~3 KB with es2016 compilation target and gzip) wrapper around SweetAlert, that, thanks to
@Decorators()
, allows us to wrap functions and make them pop modal dialogs using our favorite library.I've already had the idea months ago, and had completely forgotten about it. Then I thought about it again, as a new feature of ngx-sweetalert2, since decorators are very common in Angular, but realized quickly that it doesn't have to be an Angular thing, and that this could work anywhere, framework or not.
So I decided to make a separate project, the very one that you're seeing here.
It's an experiment. A sort of proof of concept. It's not ready for production use and lacks documentation. I'm quite sure this is a good idea (I mean, I'd use it!), but there can be many things to discuss, ideas, etc.
I'd like to hear your opinion and have your first impression. Does it seems worth it? Should I abandon it? Do you see some pitfalls? Have you ideas to improve it? :)
About the name, I first named the project
@sweetalert2/decorators
, then@sweetalert2/shields
and finally opted for@sweetalert2/guards
. I find it more pleasing to hear and "guard" is a more commonly-used technical term in CS, and seems quite appropriate here.You can now check the readme (I think it has more or less its final structure, minus most of the content) to see how it's used and what features and use cases are covered.
Hope you like it =)
(NB: it's not published on npm yet, we need to create the @sweetalert2 organization)