@types/react 16.8.20 → 16.8.21
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.
- react/README.md +3 -3
- react/index.d.ts +4 -1
- react/package.json +7 -2
react/README.md
CHANGED
@@ -2,15 +2,15 @@
|
|
2
2
|
> `npm install --save @types/react`
|
3
3
|
|
4
4
|
# Summary
|
5
|
-
This package contains type definitions for React (
|
5
|
+
This package contains type definitions for React (http://facebook.github.io/react/).
|
6
6
|
|
7
7
|
# Details
|
8
8
|
Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/react
|
9
9
|
|
10
10
|
Additional Details
|
11
|
-
* Last updated: Thu,
|
11
|
+
* Last updated: Thu, 20 Jun 2019 00:27:39 GMT
|
12
12
|
* Dependencies: @types/csstype, @types/prop-types
|
13
13
|
* Global values: React
|
14
14
|
|
15
15
|
# Credits
|
16
|
-
These definitions were written by Asana <https://asana.com>, AssureSign <http://www.assuresign.com>, Microsoft <https://microsoft.com>, John Reilly <https://github.com/johnnyreilly>, Benoit Benezech <https://github.com/bbenezech>, Patricio Zavolinsky <https://github.com/pzavolinsky>, Digiguru <https://github.com/digiguru>, Eric Anderson <https://github.com/ericanderson>, Dovydas Navickas <https://github.com/DovydasNavickas>, Stéphane Goetz <https://github.com/onigoetz>, Josh Rutherford <https://github.com/theruther4d>, Guilherme Hübner <https://github.com/guilhermehubner>, Ferdy Budhidharma <https://github.com/ferdaber>, Johann Rakotoharisoa <https://github.com/jrakotoharisoa>, Olivier Pascal <https://github.com/pascaloliv>, Martin Hochel <https://github.com/hotell>, Frank Li <https://github.com/franklixuefei>, Jessica Franco <https://github.com/Jessidhia>, Saransh Kataria <https://github.com/saranshkataria>, Kanitkorn Sujautra <https://github.com/lukyth>, Sebastian Silbermann <https://github.com/eps1lon>.
|
16
|
+
These definitions were written by Asana <https://asana.com>, AssureSign <http://www.assuresign.com>, Microsoft <https://microsoft.com>, John Reilly <https://github.com/johnnyreilly>, Benoit Benezech <https://github.com/bbenezech>, Patricio Zavolinsky <https://github.com/pzavolinsky>, Digiguru <https://github.com/digiguru>, Eric Anderson <https://github.com/ericanderson>, Dovydas Navickas <https://github.com/DovydasNavickas>, Stéphane Goetz <https://github.com/onigoetz>, Josh Rutherford <https://github.com/theruther4d>, Guilherme Hübner <https://github.com/guilhermehubner>, Ferdy Budhidharma <https://github.com/ferdaber>, Johann Rakotoharisoa <https://github.com/jrakotoharisoa>, Olivier Pascal <https://github.com/pascaloliv>, Martin Hochel <https://github.com/hotell>, Frank Li <https://github.com/franklixuefei>, Jessica Franco <https://github.com/Jessidhia>, Saransh Kataria <https://github.com/saranshkataria>, Kanitkorn Sujautra <https://github.com/lukyth>, Sebastian Silbermann <https://github.com/eps1lon>, and Chris Sauve <https://github.com/lemonmade>.
|
react/index.d.ts
CHANGED
@@ -21,6 +21,7 @@
|
|
21
21
|
// Saransh Kataria <https://github.com/saranshkataria>
|
22
22
|
// Kanitkorn Sujautra <https://github.com/lukyth>
|
23
23
|
// Sebastian Silbermann <https://github.com/eps1lon>
|
24
|
+
// Chris Sauve <https://github.com/lemonmade>
|
24
25
|
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
|
25
26
|
// TypeScript Version: 2.8
|
26
27
|
|
@@ -804,7 +805,9 @@ declare namespace React {
|
|
804
805
|
// based on the code in https://github.com/facebook/react/pull/13968
|
805
806
|
|
806
807
|
// Unlike the class component setState, the updates are not allowed to be partial
|
807
|
-
type SetStateAction<S> = S
|
808
|
+
type SetStateAction<S> = S extends ((...args: any[]) => any) ?
|
809
|
+
(prevState: S) => S :
|
810
|
+
(S | ((prevState: S) => S));
|
808
811
|
// this technically does accept a second argument, but it's already under a deprecation warning
|
809
812
|
// and it's not even released so probably better to not define it.
|
810
813
|
type Dispatch<A> = (value: A) => void;
|
react/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@types/react",
|
3
|
-
"version": "16.8.
|
3
|
+
"version": "16.8.21",
|
4
4
|
"description": "TypeScript definitions for React",
|
5
5
|
"license": "MIT",
|
6
6
|
"contributors": [
|
@@ -105,6 +105,11 @@
|
|
105
105
|
"name": "Sebastian Silbermann",
|
106
106
|
"url": "https://github.com/eps1lon",
|
107
107
|
"githubUsername": "eps1lon"
|
108
|
+
},
|
109
|
+
{
|
110
|
+
"name": "Chris Sauve",
|
111
|
+
"url": "https://github.com/lemonmade",
|
112
|
+
"githubUsername": "lemonmade"
|
108
113
|
}
|
109
114
|
],
|
110
115
|
"main": "",
|
@@ -119,6 +124,6 @@
|
|
119
124
|
"@types/prop-types": "*",
|
120
125
|
"csstype": "^2.2.0"
|
121
126
|
},
|
122
|
-
"typesPublisherContentHash": "
|
127
|
+
"typesPublisherContentHash": "1b53fe34797cce215d33ead1a08dc8b06fbcbcf3953217b222390bd90f085c33",
|
123
128
|
"typeScriptVersion": "2.8"
|
124
129
|
}
|