ui5-linter
ui5-linter copied to clipboard
refactor(SourceFileReporter): Add new addMessage signature
LGTM and I'm fine with using this for the time being.
I still find the signature somewhat complicated. It would be nice if we could limit it to a few possible parameters, maybe generalizing some of them to fit all possible messages. But I see that this might not be possible given how different some of the messages are.
An alternative to this would be to have dedicated functions per message type, each with statically typed parameters. I don't think this would make it easier for the consuming modules tough.