Skip to content

Commit 16afa18

Browse files
committed
feat: Upgrade react native 0.67.3 and its dependencies
0 parents  commit 16afa18

File tree

72 files changed

+12116
-0
lines changed

Some content is hidden

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

72 files changed

+12116
-0
lines changed

.buckconfig

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
2+
[android]
3+
target = Google Inc.:Google APIs:23
4+
5+
[maven_repositories]
6+
central = https://repo1.maven.org/maven2

.eslintrc.js

+10
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
module.exports = {
2+
root: true,
3+
extends: '@react-native-community',
4+
rules: {
5+
semi: 0,
6+
eqeqeq: 0,
7+
'no-console': 'error',
8+
'comma-dangle': ['error', 'never']
9+
}
10+
}

.flowconfig

+65
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,65 @@
1+
[ignore]
2+
; We fork some components by platform
3+
.*/*[.]android.js
4+
5+
; Ignore "BUCK" generated dirs
6+
<PROJECT_ROOT>/\.buckd/
7+
8+
; Ignore polyfills
9+
node_modules/react-native/Libraries/polyfills/.*
10+
11+
; Flow doesn't support platforms
12+
.*/Libraries/Utilities/LoadingView.js
13+
14+
[untyped]
15+
.*/node_modules/@react-native-community/cli/.*/.*
16+
17+
[include]
18+
19+
[libs]
20+
node_modules/react-native/interface.js
21+
node_modules/react-native/flow/
22+
23+
[options]
24+
emoji=true
25+
26+
exact_by_default=true
27+
28+
format.bracket_spacing=false
29+
30+
module.file_ext=.js
31+
module.file_ext=.json
32+
module.file_ext=.ios.js
33+
34+
munge_underscores=true
35+
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'
38+
39+
suppress_type=$FlowIssue
40+
suppress_type=$FlowFixMe
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
63+
64+
[version]
65+
^0.162.0

.gitignore

+62
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
# OSX
2+
#
3+
.DS_Store
4+
.bundle
5+
.vscode
6+
7+
# Xcode
8+
#
9+
build/
10+
*.pbxuser
11+
!default.pbxuser
12+
*.mode1v3
13+
!default.mode1v3
14+
*.mode2v3
15+
!default.mode2v3
16+
*.perspectivev3
17+
!default.perspectivev3
18+
xcuserdata
19+
*.xccheckout
20+
*.moved-aside
21+
DerivedData
22+
*.hmap
23+
*.ipa
24+
*.xcuserstate
25+
26+
# Android/IntelliJ
27+
#
28+
build/
29+
.idea
30+
.gradle
31+
local.properties
32+
*.iml
33+
*.hprof
34+
35+
# node.js
36+
#
37+
node_modules/
38+
npm-debug.log
39+
yarn-error.log
40+
41+
# BUCK
42+
buck-out/
43+
\.buckd/
44+
*.keystore
45+
!debug.keystore
46+
47+
# fastlane
48+
#
49+
# It is recommended to not store the screenshots in the git repo. Instead, use fastlane to re-generate the
50+
# screenshots whenever they are needed.
51+
# For more information about the recommended setup visit:
52+
# https://docs.fastlane.tools/best-practices/source-control/
53+
54+
*/fastlane/report.xml
55+
*/fastlane/Preview.html
56+
*/fastlane/screenshots
57+
58+
# Bundle artifact
59+
*.jsbundle
60+
61+
# CocoaPods
62+
/ios/Pods/

.prettierrc.js

+9
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
module.exports = {
2+
bracketSameLine: true,
3+
singleQuote: true,
4+
semi: false,
5+
tabWidth: 2,
6+
bracketSpacing: true,
7+
trailingComma: 'none',
8+
arrowParens: 'avoid'
9+
}

.ruby-version

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
2.7.4

.watchmanconfig

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
{}

Gemfile

+6
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
source 'https://rubygems.org'
2+
3+
# You may use http://rbenv.org/ or https://rvm.io/ to install and use this version
4+
ruby '2.7.4'
5+
6+
gem 'cocoapods', '~> 1.11', '>= 1.11.2'

Gemfile.lock

+100
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,100 @@
1+
GEM
2+
remote: https://rubygems.org/
3+
specs:
4+
CFPropertyList (3.0.5)
5+
rexml
6+
activesupport (6.1.4.6)
7+
concurrent-ruby (~> 1.0, >= 1.0.2)
8+
i18n (>= 1.6, < 2)
9+
minitest (>= 5.1)
10+
tzinfo (~> 2.0)
11+
zeitwerk (~> 2.3)
12+
addressable (2.8.0)
13+
public_suffix (>= 2.0.2, < 5.0)
14+
algoliasearch (1.27.5)
15+
httpclient (~> 2.8, >= 2.8.3)
16+
json (>= 1.5.1)
17+
atomos (0.1.3)
18+
claide (1.1.0)
19+
cocoapods (1.11.2)
20+
addressable (~> 2.8)
21+
claide (>= 1.0.2, < 2.0)
22+
cocoapods-core (= 1.11.2)
23+
cocoapods-deintegrate (>= 1.0.3, < 2.0)
24+
cocoapods-downloader (>= 1.4.0, < 2.0)
25+
cocoapods-plugins (>= 1.0.0, < 2.0)
26+
cocoapods-search (>= 1.0.0, < 2.0)
27+
cocoapods-trunk (>= 1.4.0, < 2.0)
28+
cocoapods-try (>= 1.1.0, < 2.0)
29+
colored2 (~> 3.1)
30+
escape (~> 0.0.4)
31+
fourflusher (>= 2.3.0, < 3.0)
32+
gh_inspector (~> 1.0)
33+
molinillo (~> 0.8.0)
34+
nap (~> 1.0)
35+
ruby-macho (>= 1.0, < 3.0)
36+
xcodeproj (>= 1.21.0, < 2.0)
37+
cocoapods-core (1.11.2)
38+
activesupport (>= 5.0, < 7)
39+
addressable (~> 2.8)
40+
algoliasearch (~> 1.0)
41+
concurrent-ruby (~> 1.1)
42+
fuzzy_match (~> 2.0.4)
43+
nap (~> 1.0)
44+
netrc (~> 0.11)
45+
public_suffix (~> 4.0)
46+
typhoeus (~> 1.0)
47+
cocoapods-deintegrate (1.0.5)
48+
cocoapods-downloader (1.5.1)
49+
cocoapods-plugins (1.0.0)
50+
nap
51+
cocoapods-search (1.0.1)
52+
cocoapods-trunk (1.6.0)
53+
nap (>= 0.8, < 2.0)
54+
netrc (~> 0.11)
55+
cocoapods-try (1.2.0)
56+
colored2 (3.1.2)
57+
concurrent-ruby (1.1.9)
58+
escape (0.0.4)
59+
ethon (0.15.0)
60+
ffi (>= 1.15.0)
61+
ffi (1.15.5)
62+
fourflusher (2.3.1)
63+
fuzzy_match (2.0.4)
64+
gh_inspector (1.1.3)
65+
httpclient (2.8.3)
66+
i18n (1.10.0)
67+
concurrent-ruby (~> 1.0)
68+
json (2.6.1)
69+
minitest (5.15.0)
70+
molinillo (0.8.0)
71+
nanaimo (0.3.0)
72+
nap (1.1.0)
73+
netrc (0.11.0)
74+
public_suffix (4.0.6)
75+
rexml (3.2.5)
76+
ruby-macho (2.5.1)
77+
typhoeus (1.4.0)
78+
ethon (>= 0.9.0)
79+
tzinfo (2.0.4)
80+
concurrent-ruby (~> 1.0)
81+
xcodeproj (1.21.0)
82+
CFPropertyList (>= 2.3.3, < 4.0)
83+
atomos (~> 0.1.3)
84+
claide (>= 1.0.2, < 2.0)
85+
colored2 (~> 3.1)
86+
nanaimo (~> 0.3.0)
87+
rexml (~> 3.2.4)
88+
zeitwerk (2.5.4)
89+
90+
PLATFORMS
91+
ruby
92+
93+
DEPENDENCIES
94+
cocoapods (~> 1.11, >= 1.11.2)
95+
96+
RUBY VERSION
97+
ruby 2.7.4p191
98+
99+
BUNDLED WITH
100+
2.2.27

README.md

+85
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,85 @@
1+
# react-native-boilerplate 2022
2+
3+
## What is React Native Boilerplate
4+
5+
It is a template that you can clone and reuse for every project. It is starting point for React Native application.
6+
7+
## React Native Boilerplate ( 0.67.3 )
8+
9+
consist of:
10+
11+
- react-native": "0.67.3"
12+
- react-navigation and its dependencies: -> React navigation 6.
13+
- @react-navigation/native: "^6.0.8
14+
- @react-navigation/native-stack: "^6.5.0"
15+
- @react-navigation/stack: "^6.1.1"
16+
- react-native-gesture-handler: "^2.2.0"
17+
- react-native-screens: "^3.13.0"
18+
- react-native-tab-view: "^3.1.1"
19+
- react-native-masked-view/masked-view: "^0.2.6"
20+
- @react-navigation/bottom-tabs: "^6.2.0"
21+
- @react-navigation/material-top-tabs: "^6.1.1"
22+
- redux -> new reduxjs/toolkit : ^1.8.0
23+
- react native vector icons: "^9.1.0"
24+
25+
more: check package.json
26+
27+
## Getting Started
28+
29+
1. Clone this repo, `git clone https://github.com/handi-dev/react-native-boilerplate.git <your project name>`
30+
2. Go to project's root directory, `cd <your project name>`
31+
3. Remove `.git` folder, `rm -rf .git`
32+
4. Use [React Native Rename](https://github.com/junedomingo/react-native-rename) to update project name `$ npx react-native-rename <newName>`
33+
5. Run `npm install` to install dependencies
34+
6. Run `npx pod-install` from root of your project.
35+
36+
If you got error like: `The version of CocoaPods used to generate the lockfile (x.x.x) is higher than the version of the current executable (x.x.x)`, then you can upgrade your cocoapods version.
37+
38+
If you install cocoapods using homebrew, you can using this command: `brew upgrade cocoapods` if that does not work, try `brew install cocoapods`.
39+
40+
If you previously install using `gem`, then use this command and run on your terminal: `sudo gem install cocoapods`.
41+
42+
make sure your cocoapods version is updated after run that command.
43+
44+
To check your current version of cocoapods, run `pod --version`.
45+
46+
After that, don't forget to execute in your terminal `pod repo update`
47+
48+
And, finally, run `npx pod-install`. Those methods must be solved that problem.
49+
50+
Last method: If All the above steps not work, remove `Podfile.lock` in folder `ios` , and then run `npx pod-install`.
51+
52+
7. Start the packager with `npm start`
53+
8. Connect your device or use emulator that's installed in your pc
54+
9. Run the test application:
55+
56+
- On Android:
57+
- Run `npx react-native run-android`
58+
- On iOS:
59+
- Open `npx react-native run-ios`
60+
61+
9. Enjoy!!!
62+
63+
## List of Q & A
64+
65+
#### I got error `Error: spawn ./gradlew EACCES` when run `npx react-native run-android`.
66+
67+
Run this command `chmod 755 android/gradlew` from your root project directory
68+
69+
#### I got error `Error: SDK location not found. Define location with sdk.dir in the local.properties file or with an ANDROID_HOME environment variable.`
70+
71+
- Go to your Project -> Android
72+
- Create a file local.properties
73+
- Open the file
74+
- Paste your Android SDK path depending on the operating system:
75+
76+
- Windows:
77+
sdk.dir=C:\\Users\\`USERNAME`\\AppData\\Local\\Android\\sdk
78+
- Linux or MacOS
79+
sdk.dir=/Users/`USERNAME`/Library/Android/sdk
80+
81+
- Replace `USERNAME` with your PC username
82+
83+
### React Native Build Failed on M1 Macbook Pro / Air
84+
85+
try this solution: [How to Run and Build React Native on Macbook Pro M1 Apple Silicon](https://handi.dev/blog/how-run-react-native-on-macbook-m1-apple-silicon)

0 commit comments

Comments
 (0)