I've already implemented this in currently private extension, figured it'd a nice feature to have here too. I'd PR this myself but I'm not too sure how to fit it in with as I'm not that familiar with the repo. Also, not sure if the implementation I have is good enough for public use. Can share code if needed.