Difference between PhantomJS 2.0 and PhantomJS 1.9

假装没事ソ 提交于 2019-12-18 07:46:08

问题


Can anyone give me the differences between those versions?

What can I do in version 2 that I could not do in earlier versions?

I use PhantomJS to execute code generated by Selenium. Will be there performance improvements?


回答1:


PhantomJS 2 has a "new" WebKit version underneath. So it changed from 534.34 in PhantomJS 1 to 538.1 in PhantomJS 2. The difference in numbers in this dimension is not big, but there is a more than two year difference between the release of the two WebKit versions. See also: Does PhantomJS use QtWebKit or Blink?

It's not that its performance is better, but rather that it supports more up-to-date web standards and APIs, and has less bugs.

Problems in the past:

  • element.click() was not available on all elements, but only on <input> and <button> elements. (Workaround)
  • PhantomJS has now Function.prototype.bind which doesn't need a shim anymore.
  • PhantomJS <1.9.8 used SSLv3 by default which broke many scripts one day.
  • PhantomJS 1 has a bug with :nth-child() selectors.


来源:https://stackoverflow.com/questions/28557100/difference-between-phantomjs-2-0-and-phantomjs-1-9

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!