initial version of texcount

This commit is contained in:
Henrique Dias
2015-06-08 18:35:24 -03:00
parent f707ad0926
commit 25d73ab6f9
5 changed files with 86 additions and 1 deletions

View File

@@ -90,3 +90,12 @@ module.exports = Client =
@compile project_id, req, callback
wordcount: (project_id, file, callback = (error, pdfPositions) ->) ->
request.get {
url: "#{@host}/project/#{project_id}/wordcount"
qs: {
file: file
}
}, (error, response, body) ->
return callback(error) if error?
callback null, JSON.parse(body)