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

Reposition and update event props are not called. #40

Closed
aight8 opened this issue Jan 7, 2017 · 5 comments
Closed

Reposition and update event props are not called. #40

aight8 opened this issue Jan 7, 2017 · 5 comments

Comments

@aight8
Copy link

aight8 commented Jan 7, 2017

No description provided.

@aight8
Copy link
Author

aight8 commented Jan 8, 2017

Sometimes the following error is showed:

this._tether.on is not a function

popup is some null (when I don't want to show). This is always the case at the beginning.

Any infos?

@souporserious
Copy link
Collaborator

@slorber any idea here? Should we just check if this._tether exists?

@alexstrat
Copy link

I actually think that _registerEventListeners should be called just after a Tether instance is created, ie roughly here: TetherComponent.jsx#L197

@slorber
Copy link
Contributor

slorber commented Jan 12, 2017

I agree with @alexstrat also had the case in my app where the tether component is hidden initially

Note that when using the imperative api you still need to make sure the tethered element is displayed otherwise you'll get the same error

@slorber
Copy link
Contributor

slorber commented Jan 12, 2017

Also note that if the fn provided as props get updated we probably should deregister/reregister on component update.

I only provided a basic initial implementation of event system but we can certainly go a lot further

souporserious added a commit that referenced this issue Feb 23, 2017
Properly call onUpdate and onRepositioned - #40
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

4 participants