Vee-validate: Validator.localize is not working. (Migrating from rc.14 to rc.18)

Created on 10 Oct 2017  ยท  3Comments  ยท  Source: logaretm/vee-validate

Versions:

  • VueJs: 2.4.4
  • Vee-Validate: 2.0.0-rc.18

Description:

In rc.14 translation of the messages was working just fine,
now if I change the Valdator.addLocale to Validator.localize the messages won't be traduced.

Also, some weird behavior with the before rule can be seen in the sandbox.
I don't know if this is related to the rc.18 or rc.14

Steps To Reproduce:

https://codesandbox.io/s/1o76z650y7

โ” question

All 3 comments

You didn't pass the locale object to localize, first parameter is the locale name, the second is the locale object itself.

https://codesandbox.io/s/6wlymvx5w3

Thanks, but what is going on with the before rule, it only works with the date_format rule in the input.
But doesn't work with the global config:

Vue.use(VeeValidate, {
  dictionary: {
    dateFormat: 'YYYY-MM-DD'
  }
});

My bad sorry, I formatted the date to a different format than the input provides.

https://codesandbox.io/s/6wlymvx5w3

Was this page helpful?
0 / 5 - 0 ratings

Related issues

schel4ok picture schel4ok  ยท  3Comments

jagasan picture jagasan  ยท  3Comments

MeltedFreddo picture MeltedFreddo  ยท  3Comments

YamenSharaf picture YamenSharaf  ยท  3Comments

kidox picture kidox  ยท  3Comments