react-storefront
react-storefront copied to clipboard
Custom submit button component for SearchField
In the code of SearchField.js
I see this:
/**
* The component to use for the submit button.
*/
SubmitButtonComponent: _propTypes["default"].elementType,
Does this mean we can pass our own custom component to be used for the submit button?
I tried this, but didn't work:
<SearchHeader>
<SearchField onChange={value => updateSearchTerm(value)} value={query} SubmitButtonComponent={CustomSearchButton} >
</SearchHeader>