You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Aug 1, 2024. It is now read-only.
var page = phantom.createPage();
var jqueryPath = path.resolve(__dirname, "jquery-3.2.1.min.js");
var babelPolyfillPath = path.resolve(__dirname, "babel-polyfill.js");
return page.run(jqueryPath, babelPolyfillPath, function (jqueryPath, babelPolyfillPath, resolve, reject) {
var page = this;
page.onInitialized = function () {
page.injectJs(babelPolyfillPath);
page.injectJs(jqueryPath);
console.log('init');
};
page.onConsoleMessage = function (msg){console.log('(PAGE CONSOLE:) '+ msg);};
page.open("http://localhost:3000/", function (status) {
var p= page.evaluate(function () {
$("button").click().click().click();
return $("div").last().text();
});
resolve(p);
});
});
})`
when in loaded page (http://localhost:3000/) used let or const (for example <script> let i=0; </script>) there occures an error:
"ReferenceError: Can't find variable: i"
The text was updated successfully, but these errors were encountered:
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
I use the code:
`.then(function (phantom) {
})`
when in loaded page (http://localhost:3000/) used let or const (for example <script> let i=0; </script>) there occures an error:
"ReferenceError: Can't find variable: i"
The text was updated successfully, but these errors were encountered: