Skip to content

Instantly share code, notes, and snippets.

@KTruong008
Last active September 23, 2017 23:00
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Save KTruong008/cbe26051fb7d4526f9a86b8b5ce6fab9 to your computer and use it in GitHub Desktop.
import React from 'react';
import { Field } from 'redux-form';
export const FormComponent = ({ handleSubmit, onSubmit }) => {
return (
<div>
<h1>My Very own Form</h1>
<form onSubmit={handleSubmit(onSubmit)}>
<Field
name="firstName"
component="input"
/>
<button type="submit">Submit</button>
</form>
</div>
);
}
export default FormComponent;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment