1.0.11 • Published 1 year ago

nv-cli-jfetch v1.0.11

Weekly downloads
-
License
ISC
Repository
-
Last release
1 year ago

nv-cli-jfetch

  • simple wrap of nodejs fetch, only can be used for repl/cli tool; coz its slow(directly use node http/https)

install

  • npm install nv-cli-jfetch

splitted

usage

  const { }   = require("nv-cli-jfetch");

example

0

0_0

0_1

1

1_0

1_1

METHODS

APIS

	const parse_wsurl = (url) => {
	const creat_tls_opts = (rejectUnauthorized=_f,key,cert)=>(new TlsOpts(rejectUnauthorized,key,cert)).dict();
	const creat_req_opts = (method,url,headers,tls_optd=creat_tls_opts(_f)) => new RequestOpts(method,url,headers,tls_optd);
	const get  = (url,headers={},tls_optd=creat_tls_opts(_f)) => {
	const get_rtrn_full = (url,headers={},tls_optd=creat_tls_opts(_f)) => {
	const get_rtrn_full_if_not_json = (url,headers={},tls_optd=creat_tls_opts(_f)) => {
	const post = (url,body={},headers={},tls_optd=creat_tls_opts(_f)) => {
	const post_rtrn_full = (url,body={},headers={},tls_optd=creat_tls_opts(_f)) => {
	const post_rtrn_full_if_not_json = (url,body={},headers={},tls_optd=creat_tls_opts(_f)) => {

LICENSE

  • ISC