Most likely its due to you importing 'request' module in a wrong way. The code below works as expected in node.js:
import * as request from 'request';
request(
{
url: 'https://www.google.co.in',
method: 'POST'
},
(res)=>
{
});
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.