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

Possibility of splitting onOpen & onClose to before & after actions? #420

Open
sdhull opened this issue Aug 4, 2018 · 5 comments
Open

Comments

@sdhull
Copy link

sdhull commented Aug 4, 2018

First I want to say thank you for this most excellent ember addon, which is so foundational to many other addons!!

Second I wanted to ask if you'd be open to deprecating onOpen and onClose in favor of beforeOpen and beforeClose as well as adding afterOpen and afterClose hooks.

Or if it's possible to achieve after hooks some other way I'd be very interested to learn!

@sdhull
Copy link
Author

sdhull commented Aug 7, 2018

In case it wasn't clear -- if you're open to considering a PR that would do this, I'm happy to take a stab at implementing it and opening a PR

@JenLyndle
Copy link

JenLyndle commented Aug 23, 2018

the afterOpen and afterClose hooks will be very helpful! Am trying to paginate my search but require the height of the component which I will not able to get onOpen(as per my understanding).

@hadiwina
Copy link

I agree with @sdhull's suggestion. The split up actions are gonna be super helpful!

Thanks for the great addon! :)

@cibernox
Copy link
Owner

I think it's a good idea, but I'm short of time lately.

The approach would be to add a onBeforeOpen/onAfterOpen and onBeforeClose/onAfterOpen, and, for backwards-compatibility, map the current onOpen/onClose to onBeforeOpen/onBeforeClose with a deprecation, to eventually be removed in 2.0.

If anyone wants to take a stab let me know, I might be able to assist

@sdhull
Copy link
Author

sdhull commented Dec 11, 2018 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants