当我执行node elementexplorer.js http://127.0.0.1:8080/app/view1时
我收到以下错误:
There was a webdriver error: Error Error while waiting for Protractor
to sync with the page: “root element (body) has no injector. this may
mean it is not inside ng-app.”
请告诉我如何提供rootelement选项.
目前,rootElement默认为body.如果您的身体没有ng-app,则会出现该错误.它可以手动设置.
原文链接:https://www.f2er.com/angularjs/141553.html您需要更改rootElement.您可以通过运行以下命令直接从交互式视图中执
browser.rootEl = 'div#ng-app-located-here';
假设您的ng-app位于div#ng-app-located-here