domenic / svg2png

Converts SVGs to PNGs, using PhantomJS
Other
585 stars 134 forks source link

Module not found: 'child_process' #86

Closed PeteMichaud closed 7 years ago

PeteMichaud commented 7 years ago

I'm trying to use this package, but I get this error when I try to require it. The issue seems to be that the pn package relies on child_process which apparently doesn't exist anymore: https://www.npmjs.com/package/child_process

This package probably needs to be updated to use a newer or existing package, but I don't know enough about how or why it was used to make the change myself.

domenic commented 7 years ago

child_process is built in to Node.js: https://nodejs.org/docs/latest/api/child_process.html

PeteMichaud commented 7 years ago

I see, so I can only use this package server side, not, for example, in a react app?

My use case is that my react app generates an svg dynamically, and I wanted to enable downloading from that app, but it seems like I'll have to pass the raw svg document back to the server for processing before the download.

domenic commented 7 years ago

Correct.