tancredi/fantasticon

Node 10 compatibility

sebastianha opened this issue · 3 comments

Hi,

according to the package.json node 10 should be sufficient:

  "engines": {
    "node": ">= 10.0.0"
  }

But when starting with node v10.22.0 I get the following error:

root@aio:~# node --version
v10.22.0
root@aio:~# fantasticon --version
1.2.3
root@aio:~# fantasticon in -o out
arr.readUint16BE is not a function

Should node 10 be compatible or is the package.json wrong? With node 16 it works fine.

Regards, Sebastian

The problem was introduced after version 1.2.2. This works fine with node 10:

root@aio:~# node --version
v10.22.0
root@aio:~# fantasticon --version
1.2.2
root@aio:~# fantasticon in -o out
Generating font kit...
✔ 1 SVG found in in
✔ Generated out/icons.eot
✔ Generated out/icons.woff2
✔ Generated out/icons.woff
✔ Generated out/icons.css
✔ Generated out/icons.html
✔ Generated out/icons.json
✔ Generated out/icons.ts
Done

Yeah, unfortunately v1.2.2 included a couple of major version bumps which dropped support for Node.js 10 and it should have been a major version bump in fantasticon. :/

That being said, even if it's wrong practice what happened here, you should move away from unsupported Node.js versions ASAP.

got same error on node v12.4.0, downgrading to 1.2.2 helped