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

Example with class #22

Closed
damianlluch opened this issue Jun 3, 2020 · 6 comments
Closed

Example with class #22

damianlluch opened this issue Jun 3, 2020 · 6 comments
Labels
question Further information is requested

Comments

@damianlluch
Copy link

Hi,! thanks for sharing.

You have any example with class?

thanks!

@benevbright
Copy link
Owner

export const Screen = withToastBannerToggler(MyScreen);

You can use withToastBannerToggler for your class component.

You will get { showBanner, hideBanner } as your prop.

@damianlluch
Copy link
Author

Mmm sorry, I'dont understand.

this is my code:

https://pastebin.com/4ZyuhyXj

You give me an example please?

thanks!

@damianlluch
Copy link
Author

For example, I try use your project when the password and de repeatPassword are diferents

@benevbright
Copy link
Owner

You can wrap your class component like

export default connect(MapStateToProps, { login })(withToastBannerToggler(Login));

Then use like this in your class

this.props.showBanner(

@benevbright benevbright added the question Further information is requested label Jun 3, 2020
@damianlluch
Copy link
Author

ok.

with parameters?

I tried with this code, but not work

https://pastebin.com/Pe5Ev6Y9

@benevbright
Copy link
Owner

Please check the README and the usage of showBanner function. https://github.com/benevbright/react-native-toast-banner#usage

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants