The fetch API is not implemented in Node.js, native support for it is only available in browsers. You need to use an external module for that, and a good one is node-fetch. After installing the module in your Node application, just add the line below to the top of the files where you are calling the fetch API:
The fetch API is not implemented in Node.js, native support for it is only available in browsers. You need to use an external module for that, and a good one is node-fetch. After installing the module in your Node application, just add the line below to the top of the files where you are calling the fetch API:
@Elena Pogorelova - Thanks this helped me