Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

can_fire_state_event? #178

Open
sporto opened this issue May 9, 2012 · 2 comments
Open

can_fire_state_event? #178

sporto opened this issue May 9, 2012 · 2 comments
Assignees
Milestone

Comments

@sporto
Copy link

sporto commented May 9, 2012

Is there something like?

document.can_fire_state_event?(:publish)

Sometimes I just don't know the name of the event I need to fire. So calling the event predicate directly is not possible. At the moment I am doing:

document.send("can_#{event_name}?")

Thanks

@venkatd
Copy link

venkatd commented May 12, 2012

I second this feature. Had the same exact thoughts.

@obrie
Copy link
Member

obrie commented May 17, 2012

This goes hand in hand with #176. I plan on adding more of these types of helpers in the future, but likely will be a month or so before we see that.

@ghost ghost assigned obrie May 17, 2012
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants