It's often the case that the rule text is sufficient to explain a rule failure; but report.error and report.warn don't have overrides that support just passing in a dom node (or a jquery object) for highlighting.
This should be possible with some run-time type checking in report.error() and report.warn() on the first argument.
If it's a string, use that as a message. If it's a DOM node or a jquery object, use those values for highlighting.
It's often the case that the rule text is sufficient to explain a rule failure; but report.error and report.warn don't have overrides that support just passing in a dom node (or a jquery object) for highlighting.
This should be possible with some run-time type checking in report.error() and report.warn() on the first argument.
If it's a string, use that as a message. If it's a DOM node or a jquery object, use those values for highlighting.