I want to have multiple masking for zip code input to accept either 5 or 9 digits. If zipcode entered is 9 digit, it should automatically add hyphen(-) in the input.
I tried optional masking(AAAAA-?A?A?A?A also tried AAAAA-A?A?A?A?) as they said in some of the closed issues on their repo, but didn't worked. There isn't any official documentation for optional characters.
Any other way to do so?