Raido
7092
6
Vue

How to check does value exists in array with Vue?

Posted 2 years ago by Raido

I have little brain teaser/freezer. I have following structure in Vue ''' data:{ country-name:'', countries: { id:'', country_name:'', }, countries:[], } ''' country_name has binding with v-model text input and should be compared with array to check is the value already entered. I understand that I should use somekind of custom filter in Vue but I have not figured out how. Can anyone provide a solution?

Please sign in or create an account to participate in this conversation.

Reply to

Use Markdown with GitHub-flavored code blocks.