When installing the JS SDK with npm i pomljs the dependency tree installs both sharp and canvas and this two link to the same native linker libraries, so OSX throws to protect you from errors:
> node test.js
objc[19597]: Class GNotificationCenterDelegate is implemented in both /Users/mau/poml-cfg/poml-to-markdown/node_modules/@img/sharp-libvips-darwin-x64/lib/libvips-cpp.42.dylib (0x13713b340) and /Users/mau/poml-cfg/poml-to-markdown/node_modules/canvas/build/Release/libgio-2.0.0.dylib (0x135a256c0). This may cause spurious casting failures and mysterious crashes. One of the duplicates must be removed or renamed.
This will be fixed later in the JS SDK, but for now a temporary workaround if you don't need images is to stub sharp (eg. in package.json):
{
...
"overrides": {
"sharp": "npm:noop2"
}
...
}
When installing the JS SDK with
npm i pomljsthe dependency tree installs bothsharpandcanvasand this two link to the same native linker libraries, so OSX throws to protect you from errors:This will be fixed later in the JS SDK, but for now a temporary workaround if you don't need images is to stub sharp (eg. in package.json):