tinify-nodejs icon indicating copy to clipboard operation
tinify-nodejs copied to clipboard

node.js version support

Open benpptung opened this issue 6 years ago • 2 comments

I'm sorry I'm still using Node.js 4 because I have no time to upgrade Nodejs, a lot of tooling, testing..I need to make sure my production server working as usual.

I see this "node": ">= 4.0" in package.json.

However, I see the following error while I'm trying to require tinify

preserve(...options) { SyntaxError: Unexpected token

I do hope to use tinify, because I have about 12,000 pics need to be optimized in our website. Is there any chance to make tinify-node.js to support Nodejs 4 ?

Thank you :)

benpptung avatar Nov 21 '18 14:11 benpptung

Hi benpptung,

I'm sorry to tell you that we do not support NodeJS versions older than 6.0.

1.6.0

  • Rewrite in TypeScript to provide automatically generated and tested types.
  • Drop support for NodeJS 4.0 and below (end of life).

I changed the version to 6.0 in package.json to avoid confusion in the future. Thanks for pointing this out to us.

jesperlofgren avatar Nov 22 '18 13:11 jesperlofgren

Hi benpptung,

If you need a simple solution, you can try and older version of the client. 1.5.0 should be the latest version that still supports it. Though keep in mind that we no longer maintain that version, so there won't be any more updates or bug fixes.

I hope this helps!

frankvanbeem avatar Nov 23 '18 08:11 frankvanbeem