characterCounter property
A custom character counter function.
Takes in the input text; returns how many characters the text should be considered as.
Implementation
@Input()
set characterCounter(CharacterCounter counterFn) {
_characterCounter = counterFn;
updateInputTextLength();
}