fetch-cookie
Advanced tools
Comparing version 2.0.3 to 2.0.4
@@ -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 |
{ | ||
"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 |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
36154
12
532
17