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

Length rule doesn't accept #836

Closed
Jomik opened this issue Sep 18, 2017 · 2 comments
Closed

Length rule doesn't accept #836

Jomik opened this issue Sep 18, 2017 · 2 comments
Labels
🐛 bug Unintended behavior

Comments

@Jomik
Copy link

Jomik commented Sep 18, 2017

Versions:

  • VueJs: 2.4.2
  • Vee-Validate:2.0.0-rc.17

Description:

I have an input field using the length rule, however when I input 4 numbers, it still does not pass.

 <input class="input" type="text" v-validate="'required|numeric|length:4'" name="building" :class="{'is-danger': errors.has('building')}" placeholder="Building" v-model="room.building" maxlength="4" size="8">

I get The building length must be 4. when writing "1234" in the field, which I should believe is 4 long.

@logaretm logaretm added the 🐛 bug Unintended behavior label Sep 18, 2017
@logaretm
Copy link
Owner

Thanks for reporting the issue, I have identified the cause being not able to handle numeric values correctly, should be released with the next tag.

At the meantime you may want to override it with a custom rule that does the same for now.

@Jomik
Copy link
Author

Jomik commented Sep 19, 2017

I am already using this repo as a dependency, as the tsc strict mode fix isn't on npm 😄

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

No branches or pull requests

2 participants