Suppose an input element has pseudo-element ::after at the end of that element, and after that there is a button, i.e. there is pseudo-element ::after between an input element and a button element. For example please look at the below picture-
In above example, when the button is clicked, after some time, the input is changed and the ::after pseudo-element gets vanished.
How can I detect that the input has ::after or not?

 
    