Skip to content

Commit a3c2dc3

Browse files
authored
Merge pull request #79 from mixpanel/add-samples
Add more sample apps for integrating Mixpanel including using Context API
2 parents 97d2f8f + a9aa0df commit a3c2dc3

File tree

200 files changed

+18681
-20
lines changed

Some content is hidden

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

200 files changed

+18681
-20
lines changed

.github/workflows/node.js.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -42,16 +42,16 @@ jobs:
4242
node-version: ${{ matrix.node-version }}
4343
- run: npm install
4444
- name: Test Integration - Install dependencies
45-
working-directory: ./MixpanelDemo
45+
working-directory: ./Samples/SimpleMixpanel
4646
run: yarn install
4747
- name: Setup Android
4848
uses: reactivecircus/android-emulator-runner@v2
4949
with:
5050
api-level: 21
51-
working-directory: ./MixpanelDemo/android
52-
script: ./gradlew connectedCheck
51+
working-directory: ./Samples/SimpleMixpanel/android
52+
script: ./gradlew
5353
- name: Test Android
54-
working-directory: ./MixpanelDemo
54+
working-directory: ./Samples/SimpleMixpanel
5555
run: yarn android
5656

5757
test_ios:
@@ -69,12 +69,12 @@ jobs:
6969
node-version: ${{ matrix.node-version }}
7070
- run: npm install
7171
- name: Test Integration - Install dependencies
72-
working-directory: ./MixpanelDemo
72+
working-directory: ./Samples/SimpleMixpanel
7373
run: yarn install
7474
- name: Setup iOS
75-
working-directory: ./MixpanelDemo/ios
75+
working-directory: ./Samples/SimpleMixpanel/ios
7676
run: pod install
7777
- name: Test iOS
78-
working-directory: ./MixpanelDemo
78+
working-directory: ./Samples/SimpleMixpanel
7979
run: yarn ios
8080

.gitignore

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,9 @@ ios/project.xcworkspace
3030
# Android
3131
android/build/
3232
android/app/
33+
android/.gradle
34+
.gradle
3335
*.idea
34-
*.gradle
3536
*.settings
3637
android/local.properties
3738
*.classpath

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,7 @@ Please refer to our [Apple App Developer Privacy Guidance](https://mixpanel.com
130130
## I want to know more!
131131

132132
No worries, here are some links that you will find useful:
133-
* **[Sample app](https://github.com/mixpanel/mixpanel-react-native/tree/master/MixpanelDemo)**
133+
* **[Sample apps](https://github.com/mixpanel/mixpanel-react-native/tree/master/Samples)**
134134
* **[Full API Reference](https://mixpanel.github.io/mixpanel-react-native/Mixpanel.html)**
135135

136136
Have any questions? Reach out to Mixpanel [Support](https://help.mixpanel.com/hc/en-us/requests/new) to speak to someone smart, quickly.
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# Windows files
2+
[*.bat]
3+
end_of_line = crlf
Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
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+
esproposal.optional_chaining=enable
27+
esproposal.nullish_coalescing=enable
28+
29+
exact_by_default=true
30+
31+
module.file_ext=.js
32+
module.file_ext=.json
33+
module.file_ext=.ios.js
34+
35+
munge_underscores=true
36+
37+
module.name_mapper='^react-native/\(.*\)$' -> '<PROJECT_ROOT>/node_modules/react-native/\1'
38+
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'
39+
40+
suppress_type=$FlowIssue
41+
suppress_type=$FlowFixMe
42+
suppress_type=$FlowFixMeProps
43+
suppress_type=$FlowFixMeState
44+
45+
[lints]
46+
sketchy-null-number=warn
47+
sketchy-null-mixed=warn
48+
sketchy-number=warn
49+
untyped-type-import=warn
50+
nonstrict-import=warn
51+
deprecated-type=warn
52+
unsafe-getters-setters=warn
53+
unnecessary-invariant=warn
54+
signature-verification-failure=warn
55+
56+
[strict]
57+
deprecated-type
58+
nonstrict-import
59+
sketchy-null
60+
unclear-type
61+
unsafe-getters-setters
62+
untyped-import
63+
untyped-type-import
64+
65+
[version]
66+
^0.137.0
Lines changed: 3 additions & 0 deletions
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
Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
# OSX
2+
#
3+
.DS_Store
4+
5+
# Xcode
6+
#
7+
build/
8+
*.pbxuser
9+
!default.pbxuser
10+
*.mode1v3
11+
!default.mode1v3
12+
*.mode2v3
13+
!default.mode2v3
14+
*.perspectivev3
15+
!default.perspectivev3
16+
xcuserdata
17+
*.xccheckout
18+
*.moved-aside
19+
DerivedData
20+
*.hmap
21+
*.ipa
22+
*.xcuserstate
23+
24+
# Android/IntelliJ
25+
#
26+
build/
27+
.idea
28+
.gradle
29+
local.properties
30+
*.iml
31+
32+
# node.js
33+
#
34+
node_modules/
35+
npm-debug.log
36+
yarn-error.log
37+
38+
# BUCK
39+
buck-out/
40+
\.buckd/
41+
*.keystore
42+
!debug.keystore
43+
44+
# fastlane
45+
#
46+
# It is recommended to not store the screenshots in the git repo. Instead, use fastlane to re-generate the
47+
# screenshots whenever they are needed.
48+
# For more information about the recommended setup visit:
49+
# https://docs.fastlane.tools/best-practices/source-control/
50+
51+
*/fastlane/report.xml
52+
*/fastlane/Preview.html
53+
*/fastlane/screenshots
54+
55+
# Bundle artifact
56+
*.jsbundle
57+
58+
# CocoaPods
59+
/ios/Pods/
60+
/ios/Podfile.lock
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
module.exports = {
2+
bracketSpacing: false,
3+
jsxBracketSameLine: true,
4+
singleQuote: true,
5+
trailingComma: 'all',
6+
arrowParens: 'avoid',
7+
};

0 commit comments

Comments
 (0)