x promise then method not working
edjroz opened this issue · comments
Subject of the issue
Promise support not working ?
Your environment
- version of node: 8.9.1
- version of npm: 5.5.1
Steps to reproduce
const Xray = require('x-ray');
const x = Xray();
x('https://blog.ycombinator.com', '.post', [{
title: 'h1 a',
link: '.article-title@href'
}]).then(res => console.log(res));
Expected behaviour
Should console log the array of news
Actual behaviour
TypeError: x(...).then is not a function
I'm getting the same result
me, too :(
same problem !
Looks like this might be related to #277.
Can you try installing with the repo clone URI? That might be a workaround.
Any update?
v2.3.2 (the current latest version on npmjs.org) was taken from a branch prior to Promise support being added. Promise support was committed to the tree prior to the 2.3.2 release, but the commits were not included in that release.
Would it be possible to release a new version? So that the last version include promises.
sorry for the delay on this folks, just pushed 2.3.3!
Thanks.
Issue can be closed.
It seems to be working. Thanks 😄