react-toggle-button
react-toggle-button copied to clipboard
ToggleButton doesn't contain value state
I am using HOC for creating input components and registering every component into the form. Because I don't want to create the wrapper every single component that I want to use. Most of the form components share common methods and props like handleChange, handleComponentChange, handleComponentBlur, componentWillReceiveProps etc... Wouldn't be better if we manage value state inside the Toggle component, not in the wrapper? But in your case, we need to create different wrappers for multiple usages in the same form. Does anybody have better approach for this? In this way, I need to make some changes to the component. Maybe we can produce a solution then I can send to PR.