import moment from 'moment'
import Vue from 'vue'
export default {
  getMessage: (field, args) => Vue.prototype.$t('Validation.ageLimit.Message', { age: args, field: field }),
  validate: (value, [ageLimit]) => {
    var years = moment().diff(value, 'years', false)
    return years >= Number.parseInt(ageLimit)
  },
}
