How to render uploaded photos with NodeJS and Express? How to render uploaded photos with NodeJS and Express? mongoose mongoose

How to render uploaded photos with NodeJS and Express?


If you just want to render thumbnail versions of your uploaded images for display, try using the imagemagick wrapper node-imagemagick.

For example, you could store your hires-images in a data-folder on your server (lets say /data/images) and render thumbnail images into a web-accessible folder (on upload).

I do not recommend generating the thumbnails on the fly, as it can massively increase your server's load when a large image (especially vector formats like eps or pdf) is being rendered.

For imagemagick examples, consider reading up the docs for the convert command.