I'm using the node-readability module to grab the title from a URL, but can't seem to use the article variable outside of the callback function.
read('http://howtonode.org/really-simple-file-uploads', function(err, article, meta) {
console.log(article.title) // this works
title = article.title
});
console.log(title) // this doesn't work
I would have expected to be able to just set the variable globally and use it as above, but that isn't working... I'm not sure if the issue is something to do with the read function in the module or my code.