Skip to content

Commit 844b662

Browse files
committed
React 17 support
1 parent 95c644d commit 844b662

File tree

5 files changed

+29
-25
lines changed

5 files changed

+29
-25
lines changed

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# 1.3.0
2+
3+
- Object constraint on form type parameter, string constraint on error type parameter. (`FormState<T extends object, State, Error extends string>`)
4+
- `FormState.errorMap` is now `ErrorMap<T, Error> | Error` instead of just `ErrorMap`.
5+
- React 17 support
6+
- Removed form argument from both `useAnyListener` and `AnyListener` render functions, because form may be accessed directly, to avoid confusion. (Breaking)

example/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,4 +45,4 @@
4545
"last 1 safari version"
4646
]
4747
}
48-
}
48+
}

example/yarn.lock

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8539,7 +8539,7 @@ prompts@^2.0.1:
85398539
kleur "^3.0.3"
85408540
sisteransi "^1.0.5"
85418541

8542-
prop-types@^15.6.2, prop-types@^15.7.2:
8542+
prop-types@^15.7.2:
85438543
version "15.7.2"
85448544
resolved "https://registry.yarnpkg.com/prop-types/-/prop-types-15.7.2.tgz#52c41e75b8c87e72b9d9360e0206b99dcbffa6c5"
85458545
integrity sha512-8QQikdH7//R2vurIJSutZ1smHYTcLpRWEOlHnzcWHmBYrOGUysKwSsrC89BCiFj3CbrfJ/nXFdJepOVrY1GCHQ==
@@ -9230,10 +9230,10 @@ saxes@^3.1.9:
92309230
dependencies:
92319231
xmlchars "^2.1.1"
92329232

9233-
scheduler@^0.19.1:
9234-
version "0.19.1"
9235-
resolved "https://registry.yarnpkg.com/scheduler/-/scheduler-0.19.1.tgz#4f3e2ed2c1a7d65681f4c854fa8c5a1ccb40f196"
9236-
integrity sha512-n/zwRWRYSUj0/3g/otKDRPMh6qv2SYMWNq85IEa8iZyAv8od9zDYpGSnpBEjNgcMNq6Scbu5KfIPxNF72R/2EA==
9233+
scheduler@^0.20.0:
9234+
version "0.20.1"
9235+
resolved "https://registry.yarnpkg.com/scheduler/-/scheduler-0.20.1.tgz#da0b907e24026b01181ecbc75efdc7f27b5a000c"
9236+
integrity sha512-LKTe+2xNJBNxu/QhHvDR14wUXHRQbVY5ZOYpOGWRzhydZUqrLb2JBvLPY7cAqFmqrWuDED0Mjk7013SZiOz6Bw==
92379237
dependencies:
92389238
loose-envify "^1.1.0"
92399239
object-assign "^4.1.1"

package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
"deploy": "gh-pages -d example/build"
2929
},
3030
"peerDependencies": {
31-
"react": "^16.0.0"
31+
"react": "^16.0.0 || ^17"
3232
},
3333
"devDependencies": {
3434
"@types/node": "^12.12.38",
@@ -38,8 +38,8 @@
3838
"gh-pages": "^2.2.0",
3939
"microbundle-crl": "^0.13.10",
4040
"prettier": "^2.0.4",
41-
"react": "^16.13.1",
42-
"react-dom": "^16.13.1",
41+
"react": "17.0.0",
42+
"react-dom": "17.0.0",
4343
"react-scripts": "^3.4.1",
4444
"typescript": "^3.7.5"
4545
},

yarn.lock

Lines changed: 14 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -8927,7 +8927,7 @@ prompts@^2.0.1:
89278927
kleur "^3.0.3"
89288928
sisteransi "^1.0.5"
89298929

8930-
prop-types@^15.6.2, prop-types@^15.7.2:
8930+
prop-types@^15.7.2:
89318931
version "15.7.2"
89328932
resolved "https://registry.yarnpkg.com/prop-types/-/prop-types-15.7.2.tgz#52c41e75b8c87e72b9d9360e0206b99dcbffa6c5"
89338933
integrity sha512-8QQikdH7//R2vurIJSutZ1smHYTcLpRWEOlHnzcWHmBYrOGUysKwSsrC89BCiFj3CbrfJ/nXFdJepOVrY1GCHQ==
@@ -9123,15 +9123,14 @@ react-dev-utils@^10.2.1:
91239123
strip-ansi "6.0.0"
91249124
text-table "0.2.0"
91259125

9126-
react-dom@^16.13.1:
9127-
version "16.14.0"
9128-
resolved "https://registry.yarnpkg.com/react-dom/-/react-dom-16.14.0.tgz#7ad838ec29a777fb3c75c3a190f661cf92ab8b89"
9129-
integrity sha512-1gCeQXDLoIqMgqD3IO2Ah9bnf0w9kzhwN5q4FGnHZ67hBm9yePzB5JJAIQCc8x3pFnNlwFq4RidZggNAAkzWWw==
9126+
react-dom@17.0.0:
9127+
version "17.0.0"
9128+
resolved "https://registry.yarnpkg.com/react-dom/-/react-dom-17.0.0.tgz#f8266e4d9861584553ccbd186d596a1c7dd8dcb4"
9129+
integrity sha512-OGnFbxCjI2TMAZYMVxi4hqheJiN8rCEVVrL7XIGzCB6beNc4Am8M47HtkvxODZw9QgjmAPKpLba9FTu4fC1byA==
91309130
dependencies:
91319131
loose-envify "^1.1.0"
91329132
object-assign "^4.1.1"
9133-
prop-types "^15.6.2"
9134-
scheduler "^0.19.1"
9133+
scheduler "^0.20.0"
91359134

91369135
react-error-overlay@^6.0.7:
91379136
version "6.0.8"
@@ -9203,14 +9202,13 @@ react-scripts@^3.4.1:
92039202
optionalDependencies:
92049203
fsevents "2.1.2"
92059204

9206-
react@^16.13.1:
9207-
version "16.14.0"
9208-
resolved "https://registry.yarnpkg.com/react/-/react-16.14.0.tgz#94d776ddd0aaa37da3eda8fc5b6b18a4c9a3114d"
9209-
integrity sha512-0X2CImDkJGApiAlcf0ODKIneSwBPhqJawOa5wCtKbu7ZECrmS26NvtSILynQ66cgkT/RJ4LidJOc3bUESwmU8g==
9205+
react@17.0.0:
9206+
version "17.0.0"
9207+
resolved "https://registry.yarnpkg.com/react/-/react-17.0.0.tgz#ad96d5fa1a33bb9b06d0cc52672f7992d84aa662"
9208+
integrity sha512-rG9bqS3LMuetoSUKHN8G3fMNuQOePKDThK6+2yXFWtoeTDLVNh/QCaxT+Jr+rNf4lwNXpx+atdn3Aa0oi8/6eQ==
92109209
dependencies:
92119210
loose-envify "^1.1.0"
92129211
object-assign "^4.1.1"
9213-
prop-types "^15.6.2"
92149212

92159213
read-pkg-up@^2.0.0:
92169214
version "2.0.0"
@@ -9803,10 +9801,10 @@ saxes@^3.1.9:
98039801
dependencies:
98049802
xmlchars "^2.1.1"
98059803

9806-
scheduler@^0.19.1:
9807-
version "0.19.1"
9808-
resolved "https://registry.yarnpkg.com/scheduler/-/scheduler-0.19.1.tgz#4f3e2ed2c1a7d65681f4c854fa8c5a1ccb40f196"
9809-
integrity sha512-n/zwRWRYSUj0/3g/otKDRPMh6qv2SYMWNq85IEa8iZyAv8od9zDYpGSnpBEjNgcMNq6Scbu5KfIPxNF72R/2EA==
9804+
scheduler@^0.20.0:
9805+
version "0.20.1"
9806+
resolved "https://registry.yarnpkg.com/scheduler/-/scheduler-0.20.1.tgz#da0b907e24026b01181ecbc75efdc7f27b5a000c"
9807+
integrity sha512-LKTe+2xNJBNxu/QhHvDR14wUXHRQbVY5ZOYpOGWRzhydZUqrLb2JBvLPY7cAqFmqrWuDED0Mjk7013SZiOz6Bw==
98109808
dependencies:
98119809
loose-envify "^1.1.0"
98129810
object-assign "^4.1.1"

0 commit comments

Comments
 (0)