Socket
Socket
Sign inDemoInstall

fetch-cookie

Package Overview
Dependencies
Maintainers
3
Versions
33
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

fetch-cookie - npm Package Compare versions

Comparing version 2.0.3 to 2.0.4

cjs/index.d.ts

7

CHANGELOG.md

@@ -9,2 +9,5 @@ # Changelog

## [2.0.4] - 2022-05-25
* Support ESM and CJS hybrid types. ([#71])
## [2.0.3] - 2022-03-16

@@ -106,3 +109,4 @@ * Fix TypeScript types, and add a test to check that TypeScript is happy

[Unreleased]: https://github.com/valeriangalliat/fetch-cookie/compare/v2.0.3...HEAD
[Unreleased]: https://github.com/valeriangalliat/fetch-cookie/compare/v2.0.4...HEAD
[2.0.4]: https://github.com/valeriangalliat/fetch-cookie/compare/v2.0.3...v2.0.4
[2.0.3]: https://github.com/valeriangalliat/fetch-cookie/compare/v2.0.2...v2.0.3

@@ -165,1 +169,2 @@ [2.0.2]: https://github.com/valeriangalliat/fetch-cookie/compare/v2.0.1...v2.0.2

[#70]: https://github.com/valeriangalliat/fetch-cookie/issues/70
[#71]: https://github.com/valeriangalliat/fetch-cookie/issues/71

24

package.json
{
"name": "fetch-cookie",
"version": "2.0.3",
"version": "2.0.4",
"description": "Decorator for a `fetch` function to support automatic cookies.",
"license": "Unlicense",
"author": "Valérian Galliat (http://val.codejam.info)",
"author": "Val (https://val.codejam.info)",
"type": "module",

@@ -11,6 +11,12 @@ "main": "./cjs/index-wrapper.js",

"exports": {
"import": "./esm/index.js",
"require": "./cjs/index-wrapper.js"
"import": {
"default": "./esm/index.js",
"types": "./esm/index.d.ts"
},
"require": {
"default": "./cjs/index-wrapper.js",
"types": "./cjs/index.d.ts"
}
},
"types": "types/index.d.ts",
"types": "esm/index.d.ts",
"repository": "valeriangalliat/fetch-cookie",

@@ -20,8 +26,9 @@ "scripts": {

"lint": "ts-standard src/*.ts test/*.js",
"patch-undici": "sed -i 's/^const forbiddenResponseHeaderNames =.*$/const forbiddenResponseHeaderNames = []/' node_modules/undici/lib/fetch/constants.js",
"prepack": "npm run prepare && npm run lint && npm run type-check && npm test",
"patch-undici": "sed -i.old 's/^const forbiddenResponseHeaderNames =.*$/const forbiddenResponseHeaderNames = []/' node_modules/undici/lib/fetch/constants.js",
"prepack": "npm run prepare && npm run lint && npm run type-check && npm test && npm run test-import",
"prepare": "npm run build && npm run type-declarations",
"test": "npm run build && mocha",
"test-import": "node test/cjs/import.js && ts-node test/cjs/import.ts",
"type-check": "tsc -noEmit",
"type-declarations": "tsc --project tsconfig.build.json --declaration --emitDeclarationOnly --outDir types"
"type-declarations": "tsc --project tsconfig.build.json --declaration --emitDeclarationOnly --outDir esm && cat esm/index.d.ts | sed 's/^export default /export = /' > cjs/index.d.ts"
},

@@ -46,2 +53,3 @@ "dependencies": {

"node-fetch": "^3.2.0",
"ts-node": "^10.7.0",
"ts-standard": "^11.0.0",

@@ -48,0 +56,0 @@ "typescript": "^4.5.5",

@@ -159,3 +159,3 @@ # 🍪 fetch-cookie [![npm version](https://img.shields.io/npm/v/fetch-cookie?style=flat-square)](https://www.npmjs.org/package/fetch-cookie) [![Build status](https://img.shields.io/github/workflow/status/valeriangalliat/fetch-cookie/Test?style=flat-square)](https://github.com/valeriangalliat/fetch-cookie/actions/workflows/test.yml)

# Allows to test node-fetch v2 as well as node-fetch v3
npm --prefix test/node-fetch-2 ci
npm --prefix test/node_modules/node-fetch-2 ci

@@ -162,0 +162,0 @@ # Allows to test against Undici by removing the blacklisting of `Set-Cookie` headers

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