Solved by checking for navigationAction.targetFrame to be nil.
NavigationType will be "other" when the webview navigates with JS (window.open, window.location.href = ''). Checking for nil will catch JS navigation to new window.
Topic:
Safari & Web
SubTopic:
General
Tags: