3 ms·
You're kidding, right? I've got heaps of experience with both, and I cringe every time I have to touch the phantomjs API. It feels like a half-assed imitation
by captainobv 14y ago
You're kidding, right?
I've got heaps of experience with both, and I cringe every time I have to touch the phantomjs API.
It feels like a half-assed imitation of node's, and for the most part isn't even internally consistent. For example, you can render to a file, or to a Base64 string. But heavens no, you can't render to stdout -- the file type is decided by the file name, so /dev/stdout is out of the question and the only workaround is making a pointless symlink. That's not to mention the showstopper bugs with it being literally impossible to exit() the process from inside a script in certain cases.
Don't get me wrong; phantom is awesome and it's great at what it does. But it's not "a dream compared to Node.js".
- mistercow 14y agoKeep in mind that I am talking specifically about the context of web scraping. For any other application, I would choose node in a heartbeat.