You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
What is the expected behavior?
Basically I'm using this to input emails for a referral invite. I want to validate on add tag thru ajax but I encountered an issue on changing a tag from valid to invalid without using the validate setting. I saw on issue #474 to set it to tagData.__isValid__= false but it looks like it changed to __isValid instead. I expect the tag when added to be invalid if the email already exists. On the demo page you can use test2@email.com as a test for the add event and test3@email.com for transformTag.
What is happening instead?
I tried both tagData.__isValid__= false and tagData.__isValid= false using a condition on add event and transformTag but it still doesn't change the tag to invalid but on the console it changed to false already.
What error message are you getting?
Unfortunately there is no error message.
The text was updated successfully, but these errors were encountered:
Hi, tagData.__isValid__ never existed, it was always just tagData.__isValid. What you saw was a mistake in my comment there (which I now edited).
You cannot set tagData.__isValid within transformTag because Tagify will ignore it. It should be handled within the validate setting. Why would you do validation within transformTag and not within the validate method?
Thank you the example you gave worked for my case! I do however have an issue with the keepInvalidTags setting when it is true. For some reason, the invalid tag thru ajax becomes valid again when I remove a valid tag. Here is the jsbin for it
Prerequisites
💥 Demo Page
https://jsbin.com/zasuqir/edit?html,js,console,output
Explanation
What is the expected behavior?
Basically I'm using this to input emails for a referral invite. I want to validate on add tag thru ajax but I encountered an issue on changing a tag from valid to invalid without using the validate setting. I saw on issue #474 to set it to
tagData.__isValid__= false
but it looks like it changed to__isValid
instead. I expect the tag when added to be invalid if the email already exists. On the demo page you can usetest2@email.com
as a test for theadd
event andtest3@email.com
fortransformTag
.What is happening instead?
I tried both
tagData.__isValid__= false
andtagData.__isValid= false
using a condition onadd
event andtransformTag
but it still doesn't change the tag to invalid but on the console it changed to false already.What error message are you getting?
Unfortunately there is no error message.
The text was updated successfully, but these errors were encountered: