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

Question: Any reason why blank placeholderChar not supported? #14

Open
mdgbayly opened this issue Mar 8, 2016 · 1 comment
Open

Question: Any reason why blank placeholderChar not supported? #14

mdgbayly opened this issue Mar 8, 2016 · 1 comment

Comments

@mdgbayly
Copy link

mdgbayly commented Mar 8, 2016

I was trying to use the react-maskedinput library to handle entering percentages with a mask like: '111%'.
Ideally I'd like to not have any placeholderChar because 9% and 99% would both be valid values too.

I tried setting the DEFAULT_PLACEHOLDER_CHAR = '' and commenting out the validation error in InputMask.

Seems to work ok for my pattern but wondering if this will likely cause issues for other patterns?

@mdgbayly mdgbayly changed the title Any reason when blank placeholderChar not supported? Question: Any reason when blank placeholderChar not supported? Mar 8, 2016
@mdgbayly mdgbayly changed the title Question: Any reason when blank placeholderChar not supported? Question: Any reason why blank placeholderChar not supported? Mar 8, 2016
@NickGard
Copy link
Contributor

NickGard commented Sep 8, 2016

@mdgbayly, with regards to your comment:

Seems to work ok for my pattern but wondering if this will likely cause issues for other patterns?

My opinion is that it is up to the consumer to set a placeholderChar that looks good with their pattern, it is not up to the library to restrict placeholderChars on the off-chance that it may not look good.

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

2 participants