I am using the webView API to load a remote site, and perform javascript operations on the site. While this works for most functions (getElementById, for instance), it doesn't seem to work for document.querySelectorAll(). When I try to use this method, I get the following error.
[WARN] Exception in event callback. { line = 18; message = "'undefined' is not a function (evaluating 'webView.evalJs(\"document.querySelectorAll('#search .g h3')[0].innerText;\")')"; name = TypeError; sourceId = 190892576; }This only seems to happen after I fill out a form dynamically with javascript and submit the Google search. Running this command in the Safari Develop Console seems to work fine. What am I missing?