Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

react-input-mask with antd #183

Closed
iloveip opened this issue Jul 14, 2019 · 1 comment
Closed

react-input-mask with antd #183

iloveip opened this issue Jul 14, 2019 · 1 comment

Comments

@iloveip
Copy link

iloveip commented Jul 14, 2019

Hi there,

Does this library work with Ant Design Input component? Is there any working example?

I tried to add it following your example like this:

const CustomInput = (props) => (
  <InputMask mask="+7 (999) 999-99-99" value={props.value} onChange={props.onChange}>
    {(inputProps) => <Input {...inputProps} />}
  </InputMask>
);

But it gives an error:

react-input-mask: the following props should be passed to the react-input-mask's component and should not be altered in children's function: disabled

Here is demo https://codesandbox.io/s/react-input-mask-test-e1oog?fontsize=14.

@iloveip iloveip closed this as completed Jul 15, 2019
@iloveip
Copy link
Author

iloveip commented Jul 15, 2019

I've posted this question in #139

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant