Skip to content

Commit a1467d1

Browse files
committed
Merge pull request #3 from BafS/microsoft-react-native-1
Move to microsoft react native and use hooks
2 parents 01cb94c + aeb00d5 commit a1467d1

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

52 files changed

+8034
-4940
lines changed

.buckconfig

-6
This file was deleted.

.editorconfig

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# Windows files
2+
[*.bat]
3+
end_of_line = crlf

.eslintrc

-237
This file was deleted.

.eslintrc.js

+4
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
module.exports = {
2+
root: true,
3+
extends: '@react-native-community',
4+
};

.flowconfig

+44-39
Original file line numberDiff line numberDiff line change
@@ -1,60 +1,65 @@
11
[ignore]
2+
; We fork some components by platform
3+
.*/*[.]android.js
24

3-
# We fork some components by platform.
4-
.*/*.android.js
5-
.*/*.ios.js
6-
7-
# Ignore templates with `@flow` in header
8-
.*/local-cli/generator.*
9-
10-
# Ignore malformed json
11-
.*/node_modules/y18n/test/.*\.json
12-
13-
# Ignore the website subdir
14-
<PROJECT_ROOT>/website/.*
15-
16-
# Ignore BUCK generated dirs
5+
; Ignore "BUCK" generated dirs
176
<PROJECT_ROOT>/\.buckd/
187

19-
# Ignore unexpected extra @providesModule
20-
.*/node_modules/commoner/test/source/widget/share.js
8+
; Ignore polyfills
9+
node_modules/react-native/Libraries/polyfills/.*
2110

22-
# Ignore duplicate module providers
23-
# For RN Apps installed via npm, "Libraries" folder is inside node_modules/react-native but in the source repo it is in the root
24-
.*/Libraries/react-native/React.js
25-
.*/Libraries/react-native/ReactNative.js
26-
.*/node_modules/jest-runtime/build/__tests__/.*
11+
; Flow doesn't support platforms
12+
.*/Libraries/Utilities/LoadingView.js
13+
14+
[untyped]
15+
.*/node_modules/@react-native-community/cli/.*/.*
2716

2817
[include]
2918

3019
[libs]
31-
node_modules/react-native-macos/Libraries/react-native/react-native-interface.js
32-
node_modules/react-native-macos/flow
33-
flow/
20+
node_modules/react-native/interface.js
21+
node_modules/react-native/flow/
3422

3523
[options]
36-
module.system=haste
24+
emoji=true
25+
26+
exact_by_default=true
3727

38-
esproposal.class_static_fields=enable
39-
esproposal.class_instance_fields=enable
28+
format.bracket_spacing=false
4029

41-
experimental.strict_type_args=true
30+
module.file_ext=.js
31+
module.file_ext=.json
32+
module.file_ext=.ios.js
4233

4334
munge_underscores=true
4435

45-
module.name_mapper='^image![a-zA-Z0-9$_-]+$' -> 'GlobalImageStub'
46-
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'
47-
module.name_mapper='react-native' -> 'react-native-macos'
36+
module.name_mapper='^react-native/\(.*\)$' -> '<PROJECT_ROOT>/node_modules/react-native/\1'
37+
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'
4838

4939
suppress_type=$FlowIssue
5040
suppress_type=$FlowFixMe
51-
suppress_type=$FixMe
52-
53-
suppress_comment=\\(.\\|\n\\)*\\$FlowFixMe\\($\\|[^(]\\|(\\(>=0\\.\\(30\\|[1-2][0-9]\\|[0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)
54-
suppress_comment=\\(.\\|\n\\)*\\$FlowIssue\\((\\(>=0\\.\\(30\\|1[0-9]\\|[1-2][0-9]\\).[0-9]\\)? *\\(site=[a-z,_]*react_native[a-z,_]*\\)?)\\)?:? #[0-9]+
55-
suppress_comment=\\(.\\|\n\\)*\\$FlowFixedInNextDeploy
56-
57-
unsafe.enable_getters_and_setters=true
41+
suppress_type=$FlowFixMeProps
42+
suppress_type=$FlowFixMeState
43+
44+
[lints]
45+
sketchy-null-number=warn
46+
sketchy-null-mixed=warn
47+
sketchy-number=warn
48+
untyped-type-import=warn
49+
nonstrict-import=warn
50+
deprecated-type=warn
51+
unsafe-getters-setters=warn
52+
unnecessary-invariant=warn
53+
signature-verification-failure=warn
54+
55+
[strict]
56+
deprecated-type
57+
nonstrict-import
58+
sketchy-null
59+
unclear-type
60+
unsafe-getters-setters
61+
untyped-import
62+
untyped-type-import
5863

5964
[version]
60-
^0.35.0
65+
^0.158.0

.gitattributes

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# Windows files should use crlf line endings
2+
# https://help.github.com/articles/dealing-with-line-endings/
3+
*.bat text eol=crlf

0 commit comments

Comments
 (0)