nise
nise copied to clipboard
WIP: Drop node 12, add node 18
The failure from FormData is caused by jsdom-global, which removes it in the cleanup.
See https://github.com/rstacruz/jsdom-global/blob/master/keys.js#L122
The jsdom-global looks pretty dead. A quick fix would be to fork it and improve it to not destroy the new globals in Node 18.... or maybe there are better libraries out there now.
The FileReader failures are because the FileReader API is not available in node, and newly added global Blob support is enabling the codepaths that use FileReader.
https://github.com/nodejs/node/pull/41270
We should probably learn how to read blobs in a node native way, not using FileReader, and save that for browsers.