Closed friday closed 6 years ago
To upgrade you need to use at least:
v2.0.0
v13.0.0
v1.0.0
The lottie-node API is the same, but you have to change how node-canvas is imported.
From this:
const Canvas = require('canvas');
To either
const {Canvas} = require('canvas');
or
const {createCanvas} = require('canvas');
createCanvas
is a function, so when you use it you must not use the new
keyword.
And that's it. To use the old version, see https://github.com/friday/lottie-node/tree/v0.2.0
node-canvas v2 has been released, and jsdom-support is coming. This may not affect this repo since v2 is primarily about font rendering, and lottie uses glyphs. Testing is needed however, and the version strings used may need to be restricted.