manuege / actions Goto Github PK
View Code? Open in Web Editor NEWAn easy way to add swift closures to UIView, UIControl and more
License: MIT License
An easy way to add swift closures to UIView, UIControl and more
License: MIT License
Is there any chance of a Swift 3 update soon?
The sample app is a mess with lots of actions linked between them.
The sample app should be separate into sections, one for each component that support actions.
Any plan to update code and support SPM?
Hi!
Thanks for this little library, I've been using Actions in production and really like it in general.
There's one thing that got me: for UIButtons, I saw that there's an addAction method, and started using it mindlessly, assuming it'd only trigger on .touchUpInside (which is I guess what 99% of the time what you're interested in if you're adding a closure to a button).
Then I kept adding more and more of those to the codebase, and the number of crashes kept increasing, and it has been really hard to figure out where they're coming from.
Then looked into the code and figured that addAction is triggered every time there's a UIControl action is received - but it was definitely not my first thought (basically only figured it out around 2-3 months in)
Which is completely fine, but this was not obvious to me from the method name. :)
Potentially this may have not been an issue if UIButton had a "addOnTouchUp" or a modified "addTap" method?
Is there any real usecase for "addAction" in general? Even using something like "onAnyAction" would make it 100% clear.
I'm writing this because it may happen to some other people, not just me:).
Can you please provide support for Carthage? Thanks.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.