Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: support old arch as well #55

Merged
merged 3 commits into from
Jul 19, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 5 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,10 @@ React Native Toast component for both Android and iOS. It just lets iOS users ha

## Summary

- extremely simple fire-and-forget api, same as `ToastAndroid`
- renders on top of `Modal`s and `Alert`s
- customizable styling
✅ supports both old and new architecture
✅ extremely simple fire-and-forget api, same as `ToastAndroid`
✅ renders on top of `Modal`s and `Alert`s
✅ customizable styling

## Screenshots

Expand Down Expand Up @@ -36,13 +37,9 @@ React Native Toast component for both Android and iOS. It just lets iOS users ha

## Install

Requires React Native 0.70 or later because the lib needs new architecture enabled. Version 2 will not work with old architecture. Use version 1 if you need to use it with the old architecture.

Please [read more about the new architecture here](https://reactnative.dev/docs/next/the-new-architecture/use-app-template#enable-the-new-architecture).

```bash
yarn add react-native-simple-toast
cd ios && RCT_NEW_ARCH_ENABLED=1 pod install
cd ios && pod install
```

then rebuild your project
Expand Down
5 changes: 2 additions & 3 deletions example/ios/Podfile
Original file line number Diff line number Diff line change
@@ -1,12 +1,11 @@
ENV['RCT_NEW_ARCH_ENABLED'] = '1'

require_relative '../node_modules/react-native/scripts/react_native_pods'
require_relative '../node_modules/react-native/scripts/native_modules'

platform :ios, min_ios_version_supported
prepare_react_native_project!

flipper_config = ENV['NO_FLIPPER'] == "1" ? FlipperConfiguration.disabled : FlipperConfiguration.enabled
# flipper_config = ENV['NO_FLIPPER'] == "1" ? FlipperConfiguration.disabled : FlipperConfiguration.enabled
flipper_config = FlipperConfiguration.disabled

linkage = ENV['USE_FRAMEWORKS']
if linkage != nil
Expand Down
Loading