Relative Content

Tag Archive for javascriptnode.jsbackend

How can I ensure token verification before image uploading?

I have a code in order to upload image in Node.js. In this code, I’m using the “multer” module for image uploading. But I want to ensure that the token of the user is verified before he or she can upload any image to my server. How can I do this?

ERR_SSL_PROTOCOL_ERROR when starting the server

after loading a small server on github, the error ERR_SSL_PROTOCOL_ERROR appears at startup on port 5000, and even when trying to create and launch another server, the error does not disappear I cleaned the browser cache, checked the date and time, cleared the dns cache, cleared the ssl cache, checked the hosts file in the system 32 folder

Is mapping response data by doing loops or map function acceptable in Node.js?

I’m working on a Node.js application where I receive a response from an API and need to process the data before sending it to the client. I’m wondering if it’s acceptable to use loops (like for or while loops) to iterate over the response data and manipulate it, or if it’s better practice to use the map function provided by JavaScript.