Open diego-v opened 2 years ago
In have this code
cf = ConversationalForm.startTheConversation({ options: { theme: 'green', submitCallback: submitCallback, preventAutoFocus: true, }, tags: tags, }); ref.current.appendChild(cf.el); return function unMount() { cf.remove(); }; }, []);
I would like to pass an argument to submitCallback in order to use it in the function:
function submitCallback(uniqueId) { var formData = cf.getFormData(true); cf.addRobotChatResponse("Listo!") actions.updateCompanyAction({ id: uniqueId, name: formData.name, country: formData.country, sites: formData.sites }); }
Is that possible?
Thanks!
Great library by the way...!
In have this code
I would like to pass an argument to submitCallback in order to use it in the function:
Is that possible?
Thanks!
Great library by the way...!