You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+29-16Lines changed: 29 additions & 16 deletions
Original file line number
Diff line number
Diff line change
@@ -1,8 +1,8 @@
1
1
# React Native SQLite + Dropbox sync demo
2
2
3
-
This project is a basic List application that demonstrates building an offline first app with SQLite and React Native (featuring TypeScript and CocoaPods under the hood). Once authorized, the database can be synced between multiple devices using Dropbox.
3
+
This project is a basic List application that demonstrates building an offline first app with SQLite and React Native (featuring TypeScript and CocoaPods under the hood). Once authorized, the database can be synced between multiple iOS devices using Dropbox.
4
4
5
-
These instructions only cover iOS usage at this time.
5
+
These instructions cover iOS and macOS usage at this time.
6
6
7
7
8
8
## Install JS dependencies
@@ -17,39 +17,52 @@ These instructions only cover iOS usage at this time.
17
17
popd
18
18
19
19
20
+
## Install macOS dependencies
21
+
22
+
pushd macos/
23
+
pod install
24
+
popd
25
+
26
+
20
27
## Start the React Native Metro Bundler
21
28
22
-
npm start
29
+
npm run start:macos
23
30
24
31
25
-
## Compile TypeScript source in watch mode
32
+
## Run (and debug) on the iOS simulator
26
33
27
-
npm run tsc -- -w
34
+
With the "React Native Tools" VSCode extension installed, open the Debug tab and press the "Play" button with "Debug iOS" selected in the dropdown.
28
35
36
+
When the simulator opens, press Command-D to open the developer menu. Tap "Debug JS Remotely" to connect VSCode to the app and enable debugging.
29
37
30
-
## Run the Jest tests in watch mode
38
+
Alternatively:
31
39
32
-
npm test
40
+
open ios/RNSQLiteDemo.xcworkspace
33
41
42
+
Select a simulator of your choice. Press the "run" button.
34
43
35
-
## Open the source in VS Code
44
+
## Run on the macOS simulator
36
45
37
-
code .
46
+
Open the macOS Xcode project:
38
47
48
+
open macos/RNSQLiteDemo.xcworkspace/
39
49
40
-
## Run (and debug) on an iOS simulator
50
+
Select `My Mac` as the "active scheme". Press the "Build and then run" (Play) button.
41
51
42
-
With the "React Native Tools" VSCode extension installed, open the Debug tab and press the "Play" button with "Debug iOS" selected in the dropdown.
43
52
44
-
When the simulator opens, press Command-D to open the developer menu. Tap "Debug JS Remotely" to connect VSCode to the app and enable debugging.
53
+
## Types and testing
45
54
46
-
Alternatively:
55
+
### Compile TypeScript source in watch mode
47
56
48
-
open ios/RNSQLiteDemo.xcworkspace
57
+
npm run tsc -- -w
58
+
59
+
60
+
### Run the Jest unit tests
61
+
62
+
npm test
49
63
50
-
Select a simulator of your choice. Press the "run" button.
51
64
52
-
## E2E Testing with Detox
65
+
###E2E Testing with Detox on iOS
53
66
54
67
End-to-end testing happens from within the `e2e/` directory:
0 commit comments