{"action":"created","issue":{"url":"https://api.github.com/repos/headzoo/surf/issues/63","repository_url":"https://api.github.com/repos/headzoo/surf","labels_url":"https://api.github.com/repos/headzoo/surf/issues/63/labels{/name}","comments_url":"https://api.github.com/repos/headzoo/surf/issues/63/comments","events_url":"https://api.github.com/repos/headzoo/surf/issues/63/events","html_url":"https://github.com/headzoo/surf/issues/63","id":244990460,"number":63,"title":"Any interest in a collaborator?","user":{"login":"lxt2","id":20478015,"avatar_url":"https://avatars0.githubusercontent.com/u/20478015?v=4","gravatar_id":"","url":"https://api.github.com/users/lxt2","html_url":"https://github.com/lxt2","followers_url":"https://api.github.com/users/lxt2/followers","following_url":"https://api.github.com/users/lxt2/following{/other_user}","gists_url":"https://api.github.com/users/lxt2/gists{/gist_id}","starred_url":"https://api.github.com/users/lxt2/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lxt2/subscriptions","organizations_url":"https://api.github.com/users/lxt2/orgs","repos_url":"https://api.github.com/users/lxt2/repos","events_url":"https://api.github.com/users/lxt2/events{/privacy}","received_events_url":"https://api.github.com/users/lxt2/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2017-07-24T07:12:08Z","updated_at":"2017-07-29T15:27:25Z","closed_at":null,"body":"There seems to a lot of open PR's and issues that could pretty easily be brought in without breaking BC.\r\n\r\nI end up using Surf quite a bit in various projects, would be quite happy to help out if you are inclined @headzoo. "},"comment":{"url":"https://api.github.com/repos/headzoo/surf/issues/comments/318838257","html_url":"https://github.com/headzoo/surf/issues/63#issuecomment-318838257","issue_url":"https://api.github.com/repos/headzoo/surf/issues/63","id":318838257,"user":{"login":"headzoo","id":707209,"avatar_url":"https://avatars3.githubusercontent.com/u/707209?v=4","gravatar_id":"","url":"https://api.github.com/users/headzoo","html_url":"https://github.com/headzoo","followers_url":"https://api.github.com/users/headzoo/followers","following_url":"https://api.github.com/users/headzoo/following{/other_user}","gists_url":"https://api.github.com/users/headzoo/gists{/gist_id}","starred_url":"https://api.github.com/users/headzoo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/headzoo/subscriptions","organizations_url":"https://api.github.com/users/headzoo/orgs","repos_url":"https://api.github.com/users/headzoo/repos","events_url":"https://api.github.com/users/headzoo/events{/privacy}","received_events_url":"https://api.github.com/users/headzoo/received_events","type":"User","site_admin":false},"created_at":"2017-07-29T15:27:25Z","updated_at":"2017-07-29T15:27:25Z","body":"I haven't written down any specific goes yet, but I have written some code. I may end up deleting the v2 branch since it only serves to document my thoughts.\r\n\r\nhttps://github.com/headzoo/surf/tree/v2\r\n\r\nMy long term goal with Surf v3.0 is having it behave like a true \"headless\" browser. Specifically giving it the ability to run javascript. Most likely by using Chrome V8 bindings. The trick with running JS inside of Surf is recreating the browser API. Chrome V8 executes Javascript, but it doesn't create a DOM or a `window` object, e.g. the whole browser API that scripts like jQuery expect to exist. That browser API has to be recreated in Surf.\r\n\r\nMy short term goal is taking the first steps towards that goal. So v2.0 will have an API similar to browsers in preparation for binding Surf to Chrome V8. It will have a new API that feels more like a real browser.\r\n\r\nSo, instead of getting the page title like this:\r\n\r\n```go\r\nbrowser := surf.NewBrowser()\r\nerr := browser.Open(\"http://golang.org\")\r\nfmt.Println(browser.Title())\r\n```\r\n\r\nIt would be done like this:\r\n\r\n```go\r\nbrowser := surf.NewBrowser()\r\nwindow := browser.Open(\"http://golang.org\")\r\nfmt.Println(window.Document.Title())\r\n```\r\n\r\nWhich mimics how the page title would be read in javascript land, e.g. by reading `window.document.title`.\r\n\r\nRight now I'm just kicking around some ideas, and not taking anything too seriously. Recreating the full browser API may be too large a task. We'll see how it goes."}}
{"actor":{"display_login":"headzoo"}}