As the title suggests I would like to know how WebStorm (or any other editor) determines whethere a string is a CSS selector.
As seen in this image, WebStorm is aware that the string passed to document.querySelector is a CSS selector and highlights it accordingly.
My own function on the otherhand does not benefit from this.
The type of selectors is string for both my method and querySelector. Is this just hard coded into the editor or do I have any way of telling it that the argument should be treated as a CSS selector?
