urllib 2.38.1 → 2.39.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/History.md +15 -0
- package/README.md +2 -2
- package/lib/index.d.ts +2 -1
- package/lib/index.test-d.ts +3 -0
- package/package.json +4 -1
package/History.md
CHANGED
@@ -1,4 +1,19 @@
|
|
1
1
|
|
2
|
+
2.39.1 / 2022-10-09
|
3
|
+
==================
|
4
|
+
|
5
|
+
**fixes**
|
6
|
+
* [[`01b54a9`](http://github.com/node-modules/urllib/commit/01b54a9fa48bdd745798fd06ad32ed41f22815d3)] - 🐛 FIX: support old ts version (fengmk2 <<fengmk2@gmail.com>>)
|
7
|
+
|
8
|
+
2.39.0 / 2022-10-09
|
9
|
+
==================
|
10
|
+
|
11
|
+
**features**
|
12
|
+
* [[`2896cf0`](http://github.com/node-modules/urllib/commit/2896cf01234184bdefc23506ec6c5aaba81d30c2)] - 👌 IMPROVE: support lower case method on d.ts (#410) (fengmk2 <<fengmk2@gmail.com>>)
|
13
|
+
|
14
|
+
**others**
|
15
|
+
* [[`0a200be`](http://github.com/node-modules/urllib/commit/0a200bec22a4fd6895e864366e66c99a8559e5f8)] - chore: change npm tag to latest-2 (fengmk2 <<fengmk2@gmail.com>>)
|
16
|
+
|
2
17
|
2.38.1 / 2022-07-05
|
3
18
|
==================
|
4
19
|
|
package/README.md
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
# urllib
|
1
|
+
# urllib@2
|
2
2
|
|
3
3
|
[![NPM version][npm-image]][npm-url]
|
4
4
|
[](https://github.com/node-modules/urllib/actions/workflows/nodejs.yml)
|
@@ -21,7 +21,7 @@ and digest authentication, redirections, cookies, timeout and more.
|
|
21
21
|
## Install
|
22
22
|
|
23
23
|
```bash
|
24
|
-
$ npm install urllib --save
|
24
|
+
$ npm install urllib@2 --save
|
25
25
|
```
|
26
26
|
|
27
27
|
## Usage
|
package/lib/index.d.ts
CHANGED
@@ -7,7 +7,8 @@ import { EventEmitter } from 'events';
|
|
7
7
|
import { LookupFunction } from 'net';
|
8
8
|
|
9
9
|
export { IncomingHttpHeaders, OutgoingHttpHeaders };
|
10
|
-
export type HttpMethod = "GET" | "POST" | "DELETE" | "PUT" | "HEAD" | "OPTIONS" | "PATCH" | "TRACE" | "CONNECT"
|
10
|
+
export type HttpMethod = "GET" | "POST" | "DELETE" | "PUT" | "HEAD" | "OPTIONS" | "PATCH" | "TRACE" | "CONNECT"
|
11
|
+
| "get" | "post" | "delete" | "put" | "head" | "options" | "patch" | "trace" | "connect";
|
11
12
|
|
12
13
|
export as namespace urllib;
|
13
14
|
export interface RequestOptions {
|
package/lib/index.test-d.ts
CHANGED
@@ -8,6 +8,9 @@ expectType<Buffer>((await curl<Buffer>('http://a.com', {})).data);
|
|
8
8
|
expectType<string>((await curl<string>('http://a.com', {
|
9
9
|
method: 'HEAD',
|
10
10
|
})).data);
|
11
|
+
expectType<string>((await curl<string>('http://a.com', {
|
12
|
+
method: 'head',
|
13
|
+
})).data);
|
11
14
|
|
12
15
|
// HttpClientResponse
|
13
16
|
const res = await curl<Buffer>('http://a.com');
|
package/package.json
CHANGED
@@ -1,6 +1,9 @@
|
|
1
1
|
{
|
2
2
|
"name": "urllib",
|
3
|
-
"version": "2.
|
3
|
+
"version": "2.39.1",
|
4
|
+
"publishConfig": {
|
5
|
+
"tag": "latest-2"
|
6
|
+
},
|
4
7
|
"description": "Help in opening URLs (mostly HTTP) in a complex world — basic and digest authentication, redirections, cookies and more.",
|
5
8
|
"keywords": [
|
6
9
|
"urllib",
|