New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

node-fetch-sync

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

node-fetch-sync

node fetch sync

latest
Source
npmnpm
Version
1.0.1
Version published
Maintainers
1
Created
Source

node-fetch-sync

基于 node-fetch@trustable/async_to_sync 实现的同步请求库。

使用方法

  const net = require('./node_fetch_sync.js');
  let url = 'https://github.com/juniorfans';
	let options = {
		timeout: 1000, 
		method: "GET", 
		proxyUrl: "http://127.0.0.1:12759",
		resultType: 'text',
	};
	
	let resObj = net.syncFetch(url, options); 

请参考 test.js

Keywords

node fetch

FAQs

Package last updated on 18 May 2020

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts