0

Ok I hope this has a simple solution. I am trying to make a validation with Vuelidate on a field to be different than an array of strings. So - sending a single string is working: not(sameAs(() =>"hello")) But trying to send an array or comma seperated values wont validate anymore :not(sameAs(() => ["hello", "helloo"])) or not(sameAs(() => "hello", "helloo")). Hopefully someone can help me, Thanks!

Jesus
  • 169
  • 2
  • 9

1 Answers1

1

Alright if anyone is interested - I just created my own validator -> usedTitles:['hello','helloo']; const checkDuplicates = () => this.usedTitles.indexOf(this.val) === -1; val.unique = checkDuplicates;

Jesus
  • 169
  • 2
  • 9