How to use with material-ui TextField and React-Final-Form?
See original GitHub issueI want use material-ui TextField like skin for Cleave and RFF for form. Can you help me?
import React from "react";
import Cleave from "cleave.js/react";
import TextField from "material-ui/TextField";
export default ({
input: { name, onChange, value, ...restInput },
meta,
...rest
}) => (
<TextField
{...rest}
name={name}
helperText={meta.touched ? meta.error : undefined}
error={meta.error && meta.touched}
inputProps={restInput}
>
<Cleave name={name} onChange={onChange} value={value}/>
</TextField>
);
Issue Analytics
- State:
- Created 5 years ago
- Comments:7 (1 by maintainers)
Top Results From Across the Web
Does [React Final Form] work with Material-UI 3.x?
You can't directly use @material-ui/core/TextField, you need to wrap it first: import React from 'react' import TextField from ...
Read more >React Final Form - Material-UI Example - CodeSandbox
Demonstrates how to use Material-UI form controls. material-ui. 18.
Read more >Examples - Final Form Docs
Demonstrates how to use React Final Form's parse and format props to control exactly how the data flows from the form state through...
Read more >react-final-form Material-UI TextField - gists · GitHub
import React from 'react';. import {FieldRenderProps} from 'react-final-form';. import TextField, {TextFieldProps} from '@material-ui/core/TextField';.
Read more >React Text Field component - Material UI - MUI
The TextField wrapper component is a complete form control including a label, input, and help text. It comes with three variants: outlined (default), ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@bogdansoare @ofarukcaki
Need create adapter with cleave.js. CleaveTextField it is adapter like in example in RFF.
Is there a way to keep the Material-UI design. I mean I did exactly like in your example but the input rendered wasn’t anything like the material-UI input.