Skip to content

Commit b67227d

Browse files
Esemesekthymikee
andauthored
chore: lib upgrades (#268)
* Update libs * Upgrade Typescript * use flowconfig from 0.61 Co-authored-by: Michał Pierzchała <[email protected]>
1 parent 88f55e2 commit b67227d

File tree

5 files changed

+618
-419
lines changed

5 files changed

+618
-419
lines changed

.flowconfig

Lines changed: 4 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,6 @@
55
; Ignore "BUCK" generated dirs
66
<PROJECT_ROOT>/\.buckd/
77

8-
; Ignore unexpected extra "@providesModule"
9-
.*/node_modules/.*/node_modules/fbjs/.*
10-
11-
; Ignore duplicate module providers
12-
; For RN Apps installed via npm, "Libraries" folder is inside
13-
; "node_modules/react-native" but in the source repo it is in the root
14-
node_modules/react-native/Libraries/react-native/React.js
15-
168
; Ignore polyfills
179
node_modules/react-native/Libraries/polyfills/.*
1810

@@ -21,11 +13,10 @@ node_modules/react-native/Libraries/polyfills/.*
2113
node_modules/warning/.*
2214

2315
; Flow doesn't support platforms
24-
.*/Libraries/Utilities/HMRLoadingView.js
16+
.*/Libraries/Utilities/LoadingView.js
2517

2618
[untyped]
2719
.*/node_modules/@react-native-community/cli/.*/.*
28-
.*/node_modules/react-native/Libraries/Lists/SectionList.js
2920

3021
[include]
3122

@@ -44,27 +35,11 @@ module.file_ext=.js
4435
module.file_ext=.json
4536
module.file_ext=.ios.js
4637

47-
module.system=haste
48-
module.system.haste.use_name_reducers=true
49-
# get basename
50-
module.system.haste.name_reducers='^.*/\([a-zA-Z0-9$_.-]+\.js\(\.flow\)?\)$' -> '\1'
51-
# strip .js or .js.flow suffix
52-
module.system.haste.name_reducers='^\(.*\)\.js\(\.flow\)?$' -> '\1'
53-
# strip .ios suffix
54-
module.system.haste.name_reducers='^\(.*\)\.ios$' -> '\1'
55-
module.system.haste.name_reducers='^\(.*\)\.android$' -> '\1'
56-
module.system.haste.name_reducers='^\(.*\)\.native$' -> '\1'
57-
module.system.haste.paths.blacklist=.*/__tests__/.*
58-
module.system.haste.paths.blacklist=.*/__mocks__/.*
59-
module.system.haste.paths.whitelist=<PROJECT_ROOT>/node_modules/react-native/Libraries/.*
60-
module.system.haste.paths.whitelist=<PROJECT_ROOT>/node_modules/react-native/RNTester/.*
61-
module.system.haste.paths.whitelist=<PROJECT_ROOT>/node_modules/react-native/IntegrationTests/.*
62-
module.system.haste.paths.blacklist=<PROJECT_ROOT>/node_modules/react-native/Libraries/react-native/react-native-implementation.js
63-
module.system.haste.paths.blacklist=<PROJECT_ROOT>/node_modules/react-native/Libraries/Animated/src/polyfills/.*
64-
6538
munge_underscores=true
6639

67-
module.name_mapper='^[./a-zA-Z0-9$_-]+\.\(bmp\|gif\|jpg\|jpeg\|png\|psd\|svg\|webp\|m4v\|mov\|mp4\|mpeg\|mpg\|webm\|aac\|aiff\|caf\|m4a\|mp3\|wav\|html\|pdf\)$' -> 'RelativeImageStub'
40+
module.name_mapper='^react-native$' -> '<PROJECT_ROOT>/node_modules/react-native/Libraries/react-native/react-native-implementation'
41+
module.name_mapper='^react-native/\(.*\)$' -> '<PROJECT_ROOT>/node_modules/react-native/\1'
42+
module.name_mapper='^[./a-zA-Z0-9$_-]+\.\(bmp\|gif\|jpg\|jpeg\|png\|psd\|svg\|webp\|m4v\|mov\|mp4\|mpeg\|mpg\|webm\|aac\|aiff\|caf\|m4a\|mp3\|wav\|html\|pdf\)$' -> '<PROJECT_ROOT>/node_modules/react-native/Libraries/Image/RelativeImageStub'
6843

6944
suppress_type=$FlowIssue
7045
suppress_type=$FlowFixMe

package.json

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -15,26 +15,27 @@
1515
"integration"
1616
],
1717
"devDependencies": {
18-
"@babel/cli": "^7.1.2",
19-
"@babel/core": "^7.1.2",
20-
"@callstack/eslint-config": "^8.0.0",
18+
"@babel/cli": "^7.8.4",
19+
"@babel/core": "^7.8.7",
20+
"@callstack/eslint-config": "^9.1.0",
2121
"@release-it/conventional-changelog": "^1.1.0",
22-
"@types/react": "^16.7.11",
23-
"@types/react-test-renderer": "^16.0.3",
22+
"@types/react": "^16.9.23",
23+
"@types/react-native": "^0.61.23",
24+
"@types/react-test-renderer": "^16.9.2",
2425
"babel-jest": "^25.1.0",
2526
"conventional-changelog-cli": "^2.0.11",
2627
"dedent": "^0.7.0",
27-
"eslint": "^6.7.2",
28+
"eslint": "^6.8.0",
2829
"flow-bin": "^0.107.0",
2930
"flow-copy-source": "^2.0.6",
3031
"jest": "^25.1.0",
31-
"metro-react-native-babel-preset": "^0.52.0",
32-
"react": "16.8.6",
33-
"react-native": "0.60.4",
34-
"react-test-renderer": "16.8.6",
32+
"metro-react-native-babel-preset": "^0.58.0",
33+
"react": "^16.13.0",
34+
"react-native": "^0.61.5",
35+
"react-test-renderer": "^16.13.0",
3536
"release-it": "^12.3.3",
3637
"strip-ansi": "^5.2.0",
37-
"typescript": "^3.7.3"
38+
"typescript": "^3.8.3"
3839
},
3940
"dependencies": {
4041
"pretty-format": "^24.0.0"

src/__tests__/__snapshots__/debug.test.js.snap

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ exports[`debug 1`] = `
1414
exports[`debug.deep 1`] = `
1515
"<View
1616
accessible={true}
17-
clickable={true}
17+
focusable={true}
1818
isTVSelectable={true}
1919
onClick={[Function bound touchableHandlePress]}
2020
onResponderGrant={[Function bound touchableHandleResponderGrant]}
@@ -38,7 +38,7 @@ exports[`debug.deep 1`] = `
3838
exports[`debug.deep async test 1`] = `
3939
"<View
4040
accessible={true}
41-
clickable={true}
41+
focusable={true}
4242
isTVSelectable={true}
4343
onClick={[Function bound touchableHandlePress]}
4444
onResponderGrant={[Function bound touchableHandleResponderGrant]}

src/__tests__/__snapshots__/render.test.js.snap

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ exports[`debug 1`] = `
2828
/>
2929
<View
3030
accessible={true}
31-
clickable={true}
31+
focusable={true}
3232
isTVSelectable={true}
3333
onClick={[Function bound touchableHandlePress]}
3434
onResponderGrant={[Function bound touchableHandleResponderGrant]}
@@ -91,7 +91,7 @@ exports[`debug changing component: bananaFresh button message should now be "fre
9191
/>
9292
<View
9393
accessible={true}
94-
clickable={true}
94+
focusable={true}
9595
isTVSelectable={true}
9696
onClick={[Function bound touchableHandlePress]}
9797
onResponderGrant={[Function bound touchableHandleResponderGrant]}
@@ -254,7 +254,7 @@ exports[`debug: with message 1`] = `
254254
/>
255255
<View
256256
accessible={true}
257-
clickable={true}
257+
focusable={true}
258258
isTVSelectable={true}
259259
onClick={[Function bound touchableHandlePress]}
260260
onResponderGrant={[Function bound touchableHandleResponderGrant]}
@@ -292,7 +292,7 @@ exports[`debug: with message 1`] = `
292292
exports[`toJSON 1`] = `
293293
<View
294294
accessible={true}
295-
clickable={false}
295+
focusable={false}
296296
isTVSelectable={true}
297297
onClick={[Function]}
298298
onResponderGrant={[Function]}

0 commit comments

Comments
 (0)