You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is there a way to call a click function on the pay button without actually clicking it?
The reason is that I'm getting the paystack key and email from an API and I want to be able to call a function to pay without clicking a different button. This is what I've tried...
<PaystackButton key="pay" text={this.state.info} ref={(payRef) => this.payRef = payRef} class="payButton" callback={this.callback} close={this.close} embed={false} reference={this.state.ref} email={this.state.email} amount={parseInt(this.state.amount)} paystackkey={this.state.p_key} tag="button" />
Then I'm calling this.payRef.payWithPaystack() but my state values are empty
The text was updated successfully, but these errors were encountered:
Is there a way to call a click function on the pay button without actually clicking it?
The reason is that I'm getting the paystack key and email from an API and I want to be able to call a function to pay without clicking a different button. This is what I've tried...
<PaystackButton key="pay" text={this.state.info} ref={(payRef) => this.payRef = payRef} class="payButton" callback={this.callback} close={this.close} embed={false} reference={this.state.ref} email={this.state.email} amount={parseInt(this.state.amount)} paystackkey={this.state.p_key} tag="button" />
Then I'm calling
this.payRef.payWithPaystack()
but my state values are emptyThe text was updated successfully, but these errors were encountered: