Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

digest-fetch

Package Overview
Dependencies
Maintainers
1
Versions
47
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

digest-fetch - npm Package Compare versions

Comparing version 0.0.1 to 0.0.2

.eslintrc

19

package.json
{
"name": "digest-fetch",
"version": "0.0.1",
"version": "0.0.2",
"description": "digest auth request plugin for fetch/node-fetch",
"main": "digest-fetch-src.js",
"scripts": {
"test": "echo \"Error: no test specified\" && exit 1",
"lint": "eslint --plugin markdown --ext js,md .",
"test": "mocha --check-leaks --bail --no-exit --reporter spec test/",
"test-cov": "istanbul cover node_modules/mocha/bin/_mocha -- --check-leaks --no-exit --reporter dot test/",
"test-travis": "istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --check-leaks --no-exit --reporter spec test/",
"build": "NODE_ENV=\"production\" webpack --optimize-minimize"

@@ -29,4 +32,12 @@ },

"webpack": "^4.6.0",
"webpack-cli": "^2.0.15"
}
"webpack-cli": "^2.0.15",
"after": "0.8.2",
"eslint": "3.19.0",
"eslint-plugin-markdown": "1.0.0-beta.6",
"express": "4.16.2",
"istanbul": "0.4.5",
"mocha": "2.5.3",
"supertest": "1.1.0"
},
"homepage": "https://github.com/devfans/digest-fetch#readme"
}
# digest-fetch
[![NPM Version][npm-image]][npm-url]
[![NPM Downloads][downloads-image]][downloads-url]
[![Build Status][travis-image]][travis-url]
[![Test Coverage][coveralls-image]][coveralls-url]
digest auth request plugin for fetch/node-fetch
## Installation
```
// dependencies for node
npm install crypto-js node-fetch
// dependencies for browser
<script src='path-to-crypto-js.js'></script>
npm install digest-fetch
```
## Get Started
```
const DigestFetch = require('digest-fetch')
const client = DigestFetch('user', 'password', console) // console as logger, optional parameter
// do request same way as fetch or node-fetch
const url = ''
const options = {}
client.fetch(url, options)
.then(resp=>resp.json())
.then(data=>console.log(data))
.catch(e=>console.error(e))
```
[npm-image]: https://img.shields.io/npm/v/digest-fetch.svg
[npm-url]: https://npmjs.org/package/digest-fetch
[travis-image]: https://img.shields.io/travis/devfans/digest-fetch/master.svg
[travis-url]: https://travis-ci.org/devfans/digest-fetch
[coveralls-image]: https://img.shields.io/coveralls/devfans/digest-fetch/master.svg
[coveralls-url]: https://coveralls.io/r/devfans/digest-fetch?branch=master
[downloads-image]: https://img.shields.io/npm/dm/digest-fetch.svg
[downloads-url]: https://npmjs.org/package/digest-fetch
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc