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

How to handle onClick event on InViewMonitor #16

Open
davidmwt opened this issue Jun 30, 2019 · 1 comment
Open

How to handle onClick event on InViewMonitor #16

davidmwt opened this issue Jun 30, 2019 · 1 comment

Comments

@davidmwt
Copy link

davidmwt commented Jun 30, 2019

Thank you for your great plugin~

I have a question on .
How to add an onClick event in it?
for example:

<InViewMonitor  onClick={this.clickHandler}>
@pocketjoso
Copy link
Contributor

Hi thanks for the feedback! I edited your post so your code example could show - you need to use triple backticks for this (3 of these ` to open/close code snippet).

As for the onClick - for now it is not supported. Would it be enough for your use case to add the onclick on the element inside the InViewMonitor? Normally that is what we would do in our own code.

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

2 participants