Skip to content

Commit

Permalink
chore: update Expo installation docs & remove config plugin (#763)
Browse files Browse the repository at this point in the history
  • Loading branch information
fobos531 authored Apr 29, 2023
1 parent dc8ca5a commit c441b9a
Show file tree
Hide file tree
Showing 12 changed files with 22 additions and 155 deletions.
20 changes: 15 additions & 5 deletions docs-react-native/react-native/docs/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,17 +59,27 @@ npx react-native run-android
## Miscellaneous

### Expo Support
Notifee has a built-in expo plugin you can install into an Expo managed project.

First, add Notifee to your project:
`npx expo install @notifee/react-native`
To be able to run Notifee, it is necessary to compile your Android app with `compileSdkVersion` of 33. As of Expo SDK 48, this is a default, so unless you're overriding the `compileSdkVersion`, there's no additional actions you need to take.

If, however, you're currently compiling your app for SDK version lower than 33, please utilize the `expo-build-properties` config plugin to bump the `compileSdkVersion` to 33. First, install `expo-build-properties`:

`npx expo install expo-build-properties`

Then, add `@notifee/react-native` to the list of plugins in your app's Expo config (`app.json` or `app.config.js`):
```json
```js
{
"name": "my app",
"plugins": [
"@notifee/react-native"
[
"expo-build-properties",
{
"android": {
"compileSdkVersion": 33,
"targetSdkVersion": 33 // Only needed if requesting permission on Android 13 via requestPermission, at least 33
},
},
],
]
}
```
Expand Down
1 change: 0 additions & 1 deletion packages/react-native/app.plugin.js

This file was deleted.

4 changes: 1 addition & 3 deletions packages/react-native/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,14 +11,12 @@
"build": "genversion --es6 --semi src/version.ts && tsc",
"build:clean": "rimraf android/libs && rimraf android/build && rimraf ios/build && rimraf dist",
"build:watch": "tsc --watch",
"build:plugin": "rimraf plugin/build && tsc --build plugin",
"prepare": "yarn run build && yarn run build:plugin",
"prepare": "yarn run build",
"prepublishOnly": "cd ../.. && yarn run build:core",
"format:android": "google-java-format --replace -i $(find . -type f -name \"*.java\")",
"format:ios": "npm_config_yes=true npx clang-format -i --glob=\"*/**/*.{h,cpp,m,mm}\" --style=Google"
},
"devDependencies": {
"@expo/config-plugins": "^4.1.0",
"@types/react-native": "0.67.2",
"@typescript-eslint/eslint-plugin": "^5.14.0",
"@typescript-eslint/parser": "^5.14.0",
Expand Down

This file was deleted.

19 changes: 0 additions & 19 deletions packages/react-native/plugin/__tests__/androidProjectBuild.test.ts

This file was deleted.

This file was deleted.

17 changes: 0 additions & 17 deletions packages/react-native/plugin/__tests__/fullPlugin.test.ts

This file was deleted.

9 changes: 0 additions & 9 deletions packages/react-native/plugin/src/index.ts

This file was deleted.

27 changes: 0 additions & 27 deletions packages/react-native/plugin/src/withNotifeeProjectGradlePlugin.ts

This file was deleted.

9 changes: 0 additions & 9 deletions packages/react-native/plugin/tsconfig.json

This file was deleted.

10 changes: 5 additions & 5 deletions tests_react_native/ios/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -358,10 +358,10 @@ PODS:
- Firebase/Messaging (= 8.15.0)
- React-Core
- RNFBApp
- RNNotifee (7.5.0):
- RNNotifee (7.7.1):
- NotifeeCore
- React-Core
- RNNotifeeCore (7.5.0):
- RNNotifeeCore (7.7.1):
- NotifeeCore
- Yoga (1.14.0)

Expand Down Expand Up @@ -546,10 +546,10 @@ SPEC CHECKSUMS:
ReactCommon: 650e33cde4fb7d36781cd3143f5276da0abb2f96
RNFBApp: e4439717c23252458da2b41b81b4b475c86f90c4
RNFBMessaging: 40dac204b4197a2661dec5be964780c6ec39bf65
RNNotifee: d4d1710905ac33ae49991ff418696fcdbd66f34d
RNNotifeeCore: e389451d7a403ef04664b220a9dfd51d8320df73
RNNotifee: 588d592046e17b959c3d48ca1ae2deb4c9c0fc37
RNNotifeeCore: 2064f1cab534e3b77a838bcf3aeec66693590397
Yoga: 90dcd029e45d8a7c1ff059e8b3c6612ff409061a

PODFILE CHECKSUM: 7b5b8be1d1de29d123a78ccb5cad509690e4f8d0

COCOAPODS: 1.11.3
COCOAPODS: 1.11.2
7 changes: 1 addition & 6 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -1098,7 +1098,7 @@
minimatch "^3.0.4"
strip-json-comments "^3.1.1"

"@expo/config-plugins@^4.1.0", "@expo/config-plugins@^4.1.5":
"@expo/config-plugins@^4.1.5":
version "4.1.5"
resolved "https://registry.yarnpkg.com/@expo/config-plugins/-/config-plugins-4.1.5.tgz#9d357d2cda9c095e511b51583ede8a3b76174068"
integrity sha512-RVvU40RtZt12HavuDAe+LDIq9lHj7sheOfMEHdmpJ/uTA8pgvkbc56XF6JHQD+yRr6+uhhb+JnAasGq49dsQbw==
Expand Down Expand Up @@ -2283,11 +2283,6 @@
"@nodelib/fs.scandir" "2.1.5"
fastq "^1.6.0"

"@notifee/react-native@*":
version "7.0.4"
resolved "https://registry.yarnpkg.com/@notifee/react-native/-/react-native-7.0.4.tgz#f0408484cd401f13baef0518d8537a3325378f3e"
integrity sha512-l41BLu3kYeVmySm9wyp/QF6yTfJoIvChn8FnGmc2WO7AR+GU54ZV3Ij6eIBS8SeHV0PLcmBiHqF9cecYXMJpUg==

"@npmcli/ci-detect@^1.0.0":
version "1.4.0"
resolved "https://registry.yarnpkg.com/@npmcli/ci-detect/-/ci-detect-1.4.0.tgz#18478bbaa900c37bfbd8a2006a6262c62e8b0fe1"
Expand Down

0 comments on commit c441b9a

Please sign in to comment.