React Reuse

Button

Example

Button example

















Show Code

Props

NameDescriptionTypeDefaultRequired
htmlIdUnique HTML ID. Used for tying label to HTML input. Handy hook for automated testing.stringX
nameInput name. Recommend setting this to match object's property so a single change handler can be used.stringX
typeInput typeenum'submit'
onClickFunction to call onClickfuncX
childrenChild component to display next to the inputnode'Submit'
sizeSize classname to use for different sizesstring''
classnameAny additional classnames to add to itstring''