Closed dovadi closed 11 years ago
I wonder why it was not using blocks from the beginning, so I'm going to let Austin merge this. There might be a reason... I don't know.
I like this a lot I just don't like changing the interface of buttons, it would be nice if you could pass them a proc, or yield a block.
OK, it's your call, but again I would choose for a block. I wouldn't maintain the proc option just for backward compatibility. In my view it would introduce extra complexibility, a lot of extra test code to maintain and this for a very young library with, I assume, flexible users who would easily adapt to the new api :-)
Very valid point
For the audience I work with (kids), I think the block is easier to understand. They're already familiar with them from core Ruby (dealing with enumerations, etc).
To us as experienced programmers, the difference between a Proc and block is actually quite small. But to new devs this might very well be the first time they ever see Proc
.
With that said let's merge this in and release the gem.
I prefer this:
instead of:
Issue: backward compatibility