1234567891011121314151617181920212223242526272829303132333435363738 |
- import React from "react";
- import { reduxForm, Field } from "redux-form";
- import authValidate from "../../utils/validate";
- const Form = props => {
- const { handleSubmit } = props
- return (
- <div className="formdiv">
- <form className="form" onSubmit={handleSubmit}>
- <h1>Material Design Text Input With No Extra Markup</h1>
-
- <Field
- name="email"
- component="input"
- type="email"
-
- placeholder="example@email.com"
- className="input"
- />
-
- <Field
- name="password"
- component="input"
- type="password"
- placeholder ="password"
- className="input"
- />
-
- <button className="button">Submit</button>
- </form>
- </div>
-
- );
- }
- export default reduxForm({ form: "authForm", validate: authValidate })(Form);
|