-
Notifications
You must be signed in to change notification settings - Fork 3.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Feature]: Make page.goto work with URL objects #1006
Comments
👋 Hi! I've been playing around with Playwright for a bit — definitely some good stuffs! I'd be interested in tackling this issue. While this looks like a straightforward enhancement, I have a few questions:
|
@aesyondu Nah, let's keep it simple. Strings work good for us so far.
@ddayguerrero Hi! I closed your PR regarding this - sorry for confusion. In general, we don't think this whole change worth the hassle - it doesn't really bother that much our clients.
This is a good one - filed #1257 to address this. |
No worries, thanks for the heads up! Shall we expect to see more newcomer friendly issues in the future? |
@ddayguerrero oh, definitely! Please keep an eye on the repo :) |
HI, await page.goto('http://www.google.com'); I need like this below way: so, plz suggested ur ideas of code for this. Thanks in advance!!! |
Context:
GOOD Playwright Version: 0.10.0BAD Playwright Version: 0.11.0Operating System: Mac OS X 10.14.6Extra: node@11.15.0 npm@6.7.0Code Snippet
Describe the
bugfeatureI have a piece of code where I construct a
URL
object and pass that to thepage.goto
function.I just noticed that the url in
page.goto
is typehinted as string:playwright/src/frames.ts
Line 325 in 39c580a
After the helper function for localhost was added, the
page.goto(URL)
now throws an error:TypeError: urlString.startsWith is not a function
playwright/src/helper.ts
Line 216 in 39c580a
I understand the alternative is to simply access the
URL.href
property, my question is:The text was updated successfully, but these errors were encountered: