├── .editorconfig ├── .gitattributes ├── .github ├── FUNDING.yml ├── ISSUE_TEMPLATE │ └── bug_report.md ├── actions │ └── setup │ │ └── action.yml └── workflows │ └── ci.yml ├── .gitignore ├── .nvmrc ├── .watchmanconfig ├── .yarnrc ├── CODE_OF_CONDUCT.md ├── CONTRIBUTING.md ├── LICENSE ├── README.md ├── babel.config.js ├── example ├── .bundle │ └── config ├── .node-version ├── .ruby-version ├── .watchmanconfig ├── Gemfile ├── android │ ├── app │ │ ├── build.gradle │ │ ├── debug.keystore │ │ ├── proguard-rules.pro │ │ └── src │ │ │ ├── debug │ │ │ ├── AndroidManifest.xml │ │ │ └── java │ │ │ │ └── com │ │ │ │ └── simpletoastexample │ │ │ │ └── ReactNativeFlipper.java │ │ │ ├── main │ │ │ ├── AndroidManifest.xml │ │ │ ├── java │ │ │ │ └── com │ │ │ │ │ └── simpletoastexample │ │ │ │ │ ├── MainActivity.java │ │ │ │ │ └── MainApplication.java │ │ │ └── res │ │ │ │ ├── drawable │ │ │ │ └── rn_edit_text_material.xml │ │ │ │ ├── mipmap-hdpi │ │ │ │ ├── ic_launcher.png │ │ │ │ └── ic_launcher_round.png │ │ │ │ ├── mipmap-mdpi │ │ │ │ ├── ic_launcher.png │ │ │ │ └── ic_launcher_round.png │ │ │ │ ├── mipmap-xhdpi │ │ │ │ ├── ic_launcher.png │ │ │ │ └── ic_launcher_round.png │ │ │ │ ├── mipmap-xxhdpi │ │ │ │ ├── ic_launcher.png │ │ │ │ └── ic_launcher_round.png │ │ │ │ ├── mipmap-xxxhdpi │ │ │ │ ├── ic_launcher.png │ │ │ │ └── ic_launcher_round.png │ │ │ │ └── values │ │ │ │ ├── strings.xml │ │ │ │ └── styles.xml │ │ │ └── release │ │ │ └── java │ │ │ └── com │ │ │ └── simpletoastexample │ │ │ └── ReactNativeFlipper.java │ ├── build.gradle │ ├── gradle.properties │ ├── gradle │ │ └── wrapper │ │ │ ├── gradle-wrapper.jar │ │ │ └── gradle-wrapper.properties │ ├── gradlew │ ├── gradlew.bat │ └── settings.gradle ├── app.json ├── babel.config.js ├── index.js ├── ios │ ├── .xcode.env │ ├── File.swift │ ├── Podfile │ ├── Podfile.lock │ ├── SimpleToastExample-Bridging-Header.h │ ├── SimpleToastExample.xcodeproj │ │ ├── project.pbxproj │ │ └── xcshareddata │ │ │ └── xcschemes │ │ │ └── SimpleToastExample.xcscheme │ ├── SimpleToastExample.xcworkspace │ │ ├── contents.xcworkspacedata │ │ └── xcshareddata │ │ │ └── IDEWorkspaceChecks.plist │ ├── SimpleToastExample │ │ ├── AppDelegate.h │ │ ├── AppDelegate.mm │ │ ├── Images.xcassets │ │ │ ├── AppIcon.appiconset │ │ │ │ └── Contents.json │ │ │ └── Contents.json │ │ ├── Info.plist │ │ ├── LaunchScreen.storyboard │ │ └── main.m │ └── SimpleToastExampleTests │ │ ├── Info.plist │ │ └── SimpleToastExampleTests.m ├── metro.config.js ├── package.json ├── react-native.config.js ├── src │ └── App.tsx └── yarn.lock ├── images ├── alert.png ├── keyboard.png ├── modal.png ├── offset.png ├── styled-keyboard.png └── styled.png ├── index.js.flow ├── ios ├── RNSimpleToast.h ├── RNSimpleToast.mm ├── RNToastView.h ├── RNToastView.m ├── RNToastViewController.h ├── RNToastViewController.m ├── RNToastWindow.h ├── RNToastWindow.m └── SimpleToast.xcodeproj │ └── project.pbxproj ├── lefthook.yml ├── package.json ├── react-native-simple-toast.podspec ├── scripts └── bootstrap.js ├── src ├── NativeSimpleToast.ts ├── __tests__ │ └── index.test.tsx └── index.ts ├── tsconfig.build.json ├── tsconfig.json └── yarn.lock /.editorconfig: -------------------------------------------------------------------------------- 1 | # EditorConfig helps developers define and maintain consistent 2 | # coding styles between different editors and IDEs 3 | # editorconfig.org 4 | 5 | root = true 6 | 7 | [*] 8 | 9 | indent_style = space 10 | indent_size = 2 11 | 12 | end_of_line = lf 13 | charset = utf-8 14 | trim_trailing_whitespace = true 15 | insert_final_newline = true 16 | -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | *.pbxproj -text 2 | # specific for windows script files 3 | *.bat text eol=crlf -------------------------------------------------------------------------------- /.github/FUNDING.yml: -------------------------------------------------------------------------------- 1 | github: [vonovak] 2 | -------------------------------------------------------------------------------- /.github/ISSUE_TEMPLATE/bug_report.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: Bug report 3 | about: Create a report to help us improve 4 | title: '' 5 | labels: '' 6 | assignees: '' 7 | 8 | --- 9 | 10 | Please [search issues before opening a new one](https://twitter.com/vonovak/status/1621272417187336193?s=20). 11 | 12 | **Describe the bug** 13 | A clear and concise description of what the bug is. 14 | 15 | **To Reproduce** 16 | Steps to reproduce the behavior: 17 | 1. Go to '...' 18 | 2. Click on '....' 19 | 3. Scroll down to '....' 20 | 4. See error 21 | 22 | **Expected behavior** 23 | A clear and concise description of what you expected to happen. 24 | 25 | **Screenshots** 26 | If applicable, add screenshots to help explain your problem. 27 | -------------------------------------------------------------------------------- /.github/actions/setup/action.yml: -------------------------------------------------------------------------------- 1 | name: Setup 2 | description: Setup Node.js and install dependencies 3 | 4 | runs: 5 | using: composite 6 | steps: 7 | - name: Setup Node.js 8 | uses: actions/setup-node@v3 9 | with: 10 | node-version-file: .nvmrc 11 | 12 | - name: Cache dependencies 13 | id: yarn-cache 14 | uses: actions/cache@v3 15 | with: 16 | path: | 17 | **/node_modules 18 | key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} 19 | restore-keys: | 20 | ${{ runner.os }}-yarn- 21 | 22 | - name: Install dependencies 23 | if: steps.yarn-cache.outputs.cache-hit != 'true' 24 | run: | 25 | yarn install --cwd example --frozen-lockfile 26 | yarn install --frozen-lockfile 27 | shell: bash 28 | -------------------------------------------------------------------------------- /.github/workflows/ci.yml: -------------------------------------------------------------------------------- 1 | name: CI 2 | on: 3 | push: 4 | branches: [master] 5 | pull_request: 6 | 7 | # Allows you to run this workflow manually from the Actions tab 8 | workflow_dispatch: 9 | 10 | jobs: 11 | lint: 12 | runs-on: ubuntu-latest 13 | steps: 14 | - name: Checkout 15 | uses: actions/checkout@v3 16 | 17 | - name: Setup 18 | uses: ./.github/actions/setup 19 | 20 | - name: Lint files 21 | run: yarn lint 22 | 23 | - name: Typecheck files 24 | run: yarn typecheck 25 | 26 | test: 27 | runs-on: ubuntu-latest 28 | steps: 29 | - name: Checkout 30 | uses: actions/checkout@v3 31 | 32 | - name: Setup 33 | uses: ./.github/actions/setup 34 | 35 | - name: Run unit tests 36 | run: yarn test --maxWorkers=2 --coverage 37 | 38 | build: 39 | runs-on: ubuntu-latest 40 | steps: 41 | - name: Checkout 42 | uses: actions/checkout@v3 43 | 44 | - name: Setup 45 | uses: ./.github/actions/setup 46 | 47 | - name: Build package 48 | run: yarn prepare 49 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # OSX 2 | # 3 | .DS_Store 4 | 5 | # VSCode 6 | .vscode/ 7 | jsconfig.json 8 | 9 | # Xcode 10 | # 11 | build/ 12 | *.pbxuser 13 | !default.pbxuser 14 | *.mode1v3 15 | !default.mode1v3 16 | *.mode2v3 17 | !default.mode2v3 18 | *.perspectivev3 19 | !default.perspectivev3 20 | xcuserdata 21 | *.xccheckout 22 | *.moved-aside 23 | DerivedData 24 | *.hmap 25 | *.ipa 26 | *.xcuserstate 27 | project.xcworkspace 28 | 29 | # Android/IJ 30 | # 31 | .classpath 32 | .cxx 33 | .gradle 34 | .idea 35 | .project 36 | .settings 37 | local.properties 38 | android.iml 39 | 40 | # Cocoapods 41 | # 42 | example/ios/Pods 43 | 44 | # Ruby 45 | example/vendor/ 46 | 47 | # node.js 48 | # 49 | node_modules/ 50 | npm-debug.log 51 | yarn-debug.log 52 | yarn-error.log 53 | 54 | # BUCK 55 | buck-out/ 56 | \.buckd/ 57 | android/app/libs 58 | android/keystores/debug.keystore 59 | 60 | # Expo 61 | .expo/ 62 | 63 | # Turborepo 64 | .turbo/ 65 | 66 | # generated by bob 67 | lib/ 68 | -------------------------------------------------------------------------------- /.nvmrc: -------------------------------------------------------------------------------- 1 | 16.18.1 2 | -------------------------------------------------------------------------------- /.watchmanconfig: -------------------------------------------------------------------------------- 1 | {} -------------------------------------------------------------------------------- /.yarnrc: -------------------------------------------------------------------------------- 1 | # Override Yarn command so we can automatically setup the repo on running `yarn` 2 | 3 | yarn-path "scripts/bootstrap.js" 4 | -------------------------------------------------------------------------------- /CODE_OF_CONDUCT.md: -------------------------------------------------------------------------------- 1 | 2 | # Contributor Covenant Code of Conduct 3 | 4 | ## Our Pledge 5 | 6 | We as members, contributors, and leaders pledge to make participation in our 7 | community a harassment-free experience for everyone, regardless of age, body 8 | size, visible or invisible disability, ethnicity, sex characteristics, gender 9 | identity and expression, level of experience, education, socio-economic status, 10 | nationality, personal appearance, race, caste, color, religion, or sexual 11 | identity and orientation. 12 | 13 | We pledge to act and interact in ways that contribute to an open, welcoming, 14 | diverse, inclusive, and healthy community. 15 | 16 | ## Our Standards 17 | 18 | Examples of behavior that contributes to a positive environment for our 19 | community include: 20 | 21 | * Demonstrating empathy and kindness toward other people 22 | * Being respectful of differing opinions, viewpoints, and experiences 23 | * Giving and gracefully accepting constructive feedback 24 | * Accepting responsibility and apologizing to those affected by our mistakes, 25 | and learning from the experience 26 | * Focusing on what is best not just for us as individuals, but for the overall 27 | community 28 | 29 | Examples of unacceptable behavior include: 30 | 31 | * The use of sexualized language or imagery, and sexual attention or advances of 32 | any kind 33 | * Trolling, insulting or derogatory comments, and personal or political attacks 34 | * Public or private harassment 35 | * Publishing others' private information, such as a physical or email address, 36 | without their explicit permission 37 | * Other conduct which could reasonably be considered inappropriate in a 38 | professional setting 39 | 40 | ## Enforcement Responsibilities 41 | 42 | Community leaders are responsible for clarifying and enforcing our standards of 43 | acceptable behavior and will take appropriate and fair corrective action in 44 | response to any behavior that they deem inappropriate, threatening, offensive, 45 | or harmful. 46 | 47 | Community leaders have the right and responsibility to remove, edit, or reject 48 | comments, commits, code, wiki edits, issues, and other contributions that are 49 | not aligned to this Code of Conduct, and will communicate reasons for moderation 50 | decisions when appropriate. 51 | 52 | ## Scope 53 | 54 | This Code of Conduct applies within all community spaces, and also applies when 55 | an individual is officially representing the community in public spaces. 56 | Examples of representing our community include using an official e-mail address, 57 | posting via an official social media account, or acting as an appointed 58 | representative at an online or offline event. 59 | 60 | ## Enforcement 61 | 62 | Instances of abusive, harassing, or otherwise unacceptable behavior may be 63 | reported to the community leaders responsible for enforcement at 64 | [INSERT CONTACT METHOD]. 65 | All complaints will be reviewed and investigated promptly and fairly. 66 | 67 | All community leaders are obligated to respect the privacy and security of the 68 | reporter of any incident. 69 | 70 | ## Enforcement Guidelines 71 | 72 | Community leaders will follow these Community Impact Guidelines in determining 73 | the consequences for any action they deem in violation of this Code of Conduct: 74 | 75 | ### 1. Correction 76 | 77 | **Community Impact**: Use of inappropriate language or other behavior deemed 78 | unprofessional or unwelcome in the community. 79 | 80 | **Consequence**: A private, written warning from community leaders, providing 81 | clarity around the nature of the violation and an explanation of why the 82 | behavior was inappropriate. A public apology may be requested. 83 | 84 | ### 2. Warning 85 | 86 | **Community Impact**: A violation through a single incident or series of 87 | actions. 88 | 89 | **Consequence**: A warning with consequences for continued behavior. No 90 | interaction with the people involved, including unsolicited interaction with 91 | those enforcing the Code of Conduct, for a specified period of time. This 92 | includes avoiding interactions in community spaces as well as external channels 93 | like social media. Violating these terms may lead to a temporary or permanent 94 | ban. 95 | 96 | ### 3. Temporary Ban 97 | 98 | **Community Impact**: A serious violation of community standards, including 99 | sustained inappropriate behavior. 100 | 101 | **Consequence**: A temporary ban from any sort of interaction or public 102 | communication with the community for a specified period of time. No public or 103 | private interaction with the people involved, including unsolicited interaction 104 | with those enforcing the Code of Conduct, is allowed during this period. 105 | Violating these terms may lead to a permanent ban. 106 | 107 | ### 4. Permanent Ban 108 | 109 | **Community Impact**: Demonstrating a pattern of violation of community 110 | standards, including sustained inappropriate behavior, harassment of an 111 | individual, or aggression toward or disparagement of classes of individuals. 112 | 113 | **Consequence**: A permanent ban from any sort of public interaction within the 114 | community. 115 | 116 | ## Attribution 117 | 118 | This Code of Conduct is adapted from the [Contributor Covenant][homepage], 119 | version 2.1, available at 120 | [https://www.contributor-covenant.org/version/2/1/code_of_conduct.html][v2.1]. 121 | 122 | Community Impact Guidelines were inspired by 123 | [Mozilla's code of conduct enforcement ladder][Mozilla CoC]. 124 | 125 | For answers to common questions about this code of conduct, see the FAQ at 126 | [https://www.contributor-covenant.org/faq][FAQ]. Translations are available at 127 | [https://www.contributor-covenant.org/translations][translations]. 128 | 129 | [homepage]: https://www.contributor-covenant.org 130 | [v2.1]: https://www.contributor-covenant.org/version/2/1/code_of_conduct.html 131 | [Mozilla CoC]: https://github.com/mozilla/diversity 132 | [FAQ]: https://www.contributor-covenant.org/faq 133 | [translations]: https://www.contributor-covenant.org/translations 134 | -------------------------------------------------------------------------------- /CONTRIBUTING.md: -------------------------------------------------------------------------------- 1 | # Contributing 2 | 3 | Contributions are always welcome, no matter how large or small! 4 | 5 | We want this community to be friendly and respectful to each other. Please follow it in all your interactions with the project. Before contributing, please read the [code of conduct](./CODE_OF_CONDUCT.md). 6 | 7 | ## Development workflow 8 | 9 | To get started with the project, run `yarn` in the root directory to install the required dependencies for each package: 10 | 11 | ```sh 12 | yarn 13 | ``` 14 | 15 | > While it's possible to use [`npm`](https://github.com/npm/cli), the tooling is built around [`yarn`](https://classic.yarnpkg.com/), so you'll have an easier time if you use `yarn` for development. 16 | 17 | While developing, you can run the [example app](/example/) to test your changes. Any changes you make in your library's JavaScript code will be reflected in the example app without a rebuild. If you change any native code, then you'll need to rebuild the example app. 18 | 19 | To start the packager: 20 | 21 | ```sh 22 | yarn example start 23 | ``` 24 | 25 | To run the example app on Android: 26 | 27 | ```sh 28 | yarn example android 29 | ``` 30 | 31 | To run the example app on iOS: 32 | 33 | ```sh 34 | yarn example ios 35 | ``` 36 | 37 | To confirm that the app is running with the new architecture, you can check the Metro logs for a message like this: 38 | 39 | ```sh 40 | Running "SimpleToastExample" with {"fabric":true,"initialProps":{"concurrentRoot":true},"rootTag":1} 41 | ``` 42 | 43 | Note the `"fabric":true` and `"concurrentRoot":true` properties. 44 | 45 | Make sure your code passes TypeScript and ESLint. Run the following to verify: 46 | 47 | ```sh 48 | yarn typecheck 49 | yarn lint 50 | ``` 51 | 52 | To fix formatting errors, run the following: 53 | 54 | ```sh 55 | yarn lint --fix 56 | ``` 57 | 58 | Remember to add tests for your change if possible. Run the unit tests by: 59 | 60 | ```sh 61 | yarn test 62 | ``` 63 | 64 | To edit the Objective-C or Swift files, open `example/ios/SimpleToastExample.xcworkspace` in XCode and find the source files at `Pods > Development Pods > react-native-simple-toast`. 65 | 66 | To edit the Java or Kotlin files, open `example/android` in Android studio and find the source files at `react-native-simple-toast` under `Android`. 67 | 68 | 69 | ### Commit message convention 70 | 71 | We follow the [conventional commits specification](https://www.conventionalcommits.org/en) for our commit messages: 72 | 73 | - `fix`: bug fixes, e.g. fix crash due to deprecated method. 74 | - `feat`: new features, e.g. add new method to the module. 75 | - `refactor`: code refactor, e.g. migrate from class components to hooks. 76 | - `docs`: changes into documentation, e.g. add usage example for the module.. 77 | - `test`: adding or updating tests, e.g. add integration tests using detox. 78 | - `chore`: tooling changes, e.g. change CI config. 79 | 80 | Our pre-commit hooks verify that your commit message matches this format when committing. 81 | 82 | ### Linting and tests 83 | 84 | [ESLint](https://eslint.org/), [Prettier](https://prettier.io/), [TypeScript](https://www.typescriptlang.org/) 85 | 86 | We use [TypeScript](https://www.typescriptlang.org/) for type checking, [ESLint](https://eslint.org/) with [Prettier](https://prettier.io/) for linting and formatting the code, and [Jest](https://jestjs.io/) for testing. 87 | 88 | Our pre-commit hooks verify that the linter and tests pass when committing. 89 | 90 | ### Publishing to npm 91 | 92 | We use [release-it](https://github.com/release-it/release-it) to make it easier to publish new versions. It handles common tasks like bumping version based on semver, creating tags and releases etc. 93 | 94 | To publish new versions, run the following: 95 | 96 | ```sh 97 | yarn release 98 | ``` 99 | 100 | ### Scripts 101 | 102 | The `package.json` file contains various scripts for common tasks: 103 | 104 | - `yarn bootstrap`: setup project by installing all dependencies and pods. 105 | - `yarn typecheck`: type-check files with TypeScript. 106 | - `yarn lint`: lint files with ESLint. 107 | - `yarn test`: run unit tests with Jest. 108 | - `yarn example start`: start the Metro server for the example app. 109 | - `yarn example android`: run the example app on Android. 110 | - `yarn example ios`: run the example app on iOS. 111 | 112 | ### Sending a pull request 113 | 114 | > **Working on your first pull request?** You can learn how from this _free_ series: [How to Contribute to an Open Source Project on GitHub](https://app.egghead.io/playlists/how-to-contribute-to-an-open-source-project-on-github). 115 | 116 | When you're sending a pull request: 117 | 118 | - Prefer small pull requests focused on one change. 119 | - Verify that linters and tests are passing. 120 | - Review the documentation to make sure it looks good. 121 | - Follow the pull request template when opening a pull request. 122 | - For pull requests that change the API or implementation, discuss with maintainers first by opening an issue. 123 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2022 Vojtech Novak 4 | Permission is hereby granted, free of charge, to any person obtaining a copy 5 | of this software and associated documentation files (the "Software"), to deal 6 | in the Software without restriction, including without limitation the rights 7 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 8 | copies of the Software, and to permit persons to whom the Software is 9 | furnished to do so, subject to the following conditions: 10 | 11 | The above copyright notice and this permission notice shall be included in all 12 | copies or substantial portions of the Software. 13 | 14 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 15 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 16 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 17 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 18 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 19 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 20 | SOFTWARE. 21 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # react-native-simple-toast [![npm version](https://badge.fury.io/js/react-native-simple-toast.svg)](https://badge.fury.io/js/react-native-simple-toast) 2 | 3 | React Native Toast component for both Android and iOS. It just lets iOS users have the same toast experience as on Android. Using [scalessec/Toast](https://github.com/scalessec/Toast) on iOS and the React Native's [ToastAndroid](http://facebook.github.io/react-native/docs/toastandroid.html) on Android. 4 | 5 | ## Summary 6 | 7 | ✅ supports both old and new architecture (RN >= 0.71 is required for new arch) 8 | 9 | ✅ extremely simple fire-and-forget api, same as `ToastAndroid` 10 | 11 | ✅ renders on top of `Modal`s and `Alert`s 12 | 13 | ✅ avoids keyboard 14 | 15 | ✅ customizable styling 16 | 17 | ## Screenshots 18 | 19 | 20 | 21 | 22 | 23 | 24 | 25 |

26 | 27 |
28 | Expand for more screenshots 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 |

40 | 41 |
42 | 43 | ## Install 44 | 45 | ```bash 46 | yarn add react-native-simple-toast 47 | cd ios && pod install 48 | ``` 49 | 50 | then rebuild your project 51 | 52 | ## Usage 53 | 54 | the module exposes the following functions, same as `ToastAndroid`, with extra configuration parameter for iOS only: 55 | 56 | ```ts 57 | import Toast from 'react-native-simple-toast'; 58 | 59 | Toast.show(message, duration, options); 60 | 61 | Toast.showWithGravity(message, duration, gravity, options); 62 | 63 | Toast.showWithGravityAndOffset( 64 | message, 65 | duration, 66 | gravity, 67 | xOffset, 68 | yOffset, 69 | options, 70 | ); 71 | ``` 72 | 73 | exported duration and positioning constants: 74 | 75 | ```ts 76 | import Toast from 'react-native-simple-toast'; 77 | 78 | Toast.LONG; 79 | Toast.SHORT; 80 | Toast.TOP; 81 | Toast.BOTTOM; 82 | Toast.CENTER; 83 | ``` 84 | 85 | Please note that `yOffset` and `xOffset` are [ignored on Android 11 and above](). 86 | 87 | For customizing on iOS, you can pass an object with the following properties: 88 | 89 | ```ts 90 | type OptionsIOS = { 91 | textColor?: ColorValue; 92 | backgroundColor?: ColorValue; 93 | tapToDismissEnabled?: boolean; 94 | }; 95 | ``` 96 | 97 | ## Examples 98 | 99 | ```js 100 | import Toast from 'react-native-simple-toast'; 101 | 102 | Toast.show('This is a short toast'); 103 | 104 | Toast.show('This is a long toast.', Toast.LONG); 105 | 106 | Toast.showWithGravity( 107 | 'This is a long toast at the top.', 108 | Toast.LONG, 109 | Toast.TOP, 110 | ); 111 | 112 | Toast.show('This is a styled toast on iOS.', Toast.LONG, { 113 | backgroundColor: 'blue', 114 | }); 115 | 116 | Toast.show('This is a toast that can be dismissed (iOS only).', Toast.LONG, { 117 | tapToDismissEnabled: true, 118 | }); 119 | ``` 120 | 121 | ## License 122 | 123 | MIT 124 | 125 | --- 126 | 127 | Made with [create-react-native-library](https://github.com/callstack/react-native-builder-bob) 128 | -------------------------------------------------------------------------------- /babel.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | presets: ['module:metro-react-native-babel-preset'], 3 | }; 4 | -------------------------------------------------------------------------------- /example/.bundle/config: -------------------------------------------------------------------------------- 1 | BUNDLE_PATH: "vendor/bundle" 2 | BUNDLE_FORCE_RUBY_PLATFORM: 1 3 | -------------------------------------------------------------------------------- /example/.node-version: -------------------------------------------------------------------------------- 1 | 16 2 | -------------------------------------------------------------------------------- /example/.ruby-version: -------------------------------------------------------------------------------- 1 | 2.7.6 2 | -------------------------------------------------------------------------------- /example/.watchmanconfig: -------------------------------------------------------------------------------- 1 | {} -------------------------------------------------------------------------------- /example/Gemfile: -------------------------------------------------------------------------------- 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 File.read(File.join(__dir__, '.ruby-version')).strip 5 | 6 | gem 'cocoapods', '~> 1.11', '>= 1.11.3' 7 | -------------------------------------------------------------------------------- /example/android/app/build.gradle: -------------------------------------------------------------------------------- 1 | apply plugin: "com.android.application" 2 | apply plugin: "com.facebook.react" 3 | 4 | import com.android.build.OutputFile 5 | 6 | /** 7 | * This is the configuration block to customize your React Native Android app. 8 | * By default you don't need to apply any configuration, just uncomment the lines you need. 9 | */ 10 | react { 11 | /* Folders */ 12 | // The root of your project, i.e. where "package.json" lives. Default is '..' 13 | // root = file("../") 14 | // The folder where the react-native NPM package is. Default is ../node_modules/react-native 15 | // reactNativeDir = file("../node-modules/react-native") 16 | // The folder where the react-native Codegen package is. Default is ../node_modules/react-native-codegen 17 | // codegenDir = file("../node-modules/react-native-codegen") 18 | // The cli.js file which is the React Native CLI entrypoint. Default is ../node_modules/react-native/cli.js 19 | // cliFile = file("../node_modules/react-native/cli.js") 20 | 21 | /* Variants */ 22 | // The list of variants to that are debuggable. For those we're going to 23 | // skip the bundling of the JS bundle and the assets. By default is just 'debug'. 24 | // If you add flavors like lite, prod, etc. you'll have to list your debuggableVariants. 25 | // debuggableVariants = ["liteDebug", "prodDebug"] 26 | 27 | /* Bundling */ 28 | // A list containing the node command and its flags. Default is just 'node'. 29 | // nodeExecutableAndArgs = ["node"] 30 | // 31 | // The command to run when bundling. By default is 'bundle' 32 | // bundleCommand = "ram-bundle" 33 | // 34 | // The path to the CLI configuration file. Default is empty. 35 | // bundleConfig = file(../rn-cli.config.js) 36 | // 37 | // The name of the generated asset file containing your JS bundle 38 | // bundleAssetName = "MyApplication.android.bundle" 39 | // 40 | // The entry file for bundle generation. Default is 'index.android.js' or 'index.js' 41 | // entryFile = file("../js/MyApplication.android.js") 42 | // 43 | // A list of extra flags to pass to the 'bundle' commands. 44 | // See https://github.com/react-native-community/cli/blob/main/docs/commands.md#bundle 45 | // extraPackagerArgs = [] 46 | 47 | /* Hermes Commands */ 48 | // The hermes compiler command to run. By default it is 'hermesc' 49 | // hermesCommand = "$rootDir/my-custom-hermesc/bin/hermesc" 50 | // 51 | // The list of flags to pass to the Hermes compiler. By default is "-O", "-output-source-map" 52 | // hermesFlags = ["-O", "-output-source-map"] 53 | } 54 | 55 | /** 56 | * Set this to true to create four separate APKs instead of one, 57 | * one for each native architecture. This is useful if you don't 58 | * use App Bundles (https://developer.android.com/guide/app-bundle/) 59 | * and want to have separate APKs to upload to the Play Store. 60 | */ 61 | def enableSeparateBuildPerCPUArchitecture = false 62 | 63 | /** 64 | * Set this to true to Run Proguard on Release builds to minify the Java bytecode. 65 | */ 66 | def enableProguardInReleaseBuilds = false 67 | 68 | /** 69 | * The preferred build flavor of JavaScriptCore (JSC) 70 | * 71 | * For example, to use the international variant, you can use: 72 | * `def jscFlavor = 'org.webkit:android-jsc-intl:+'` 73 | * 74 | * The international variant includes ICU i18n library and necessary data 75 | * allowing to use e.g. `Date.toLocaleString` and `String.localeCompare` that 76 | * give correct results when using with locales other than en-US. Note that 77 | * this variant is about 6MiB larger per architecture than default. 78 | */ 79 | def jscFlavor = 'org.webkit:android-jsc:+' 80 | 81 | /** 82 | * Private function to get the list of Native Architectures you want to build. 83 | * This reads the value from reactNativeArchitectures in your gradle.properties 84 | * file and works together with the --active-arch-only flag of react-native run-android. 85 | */ 86 | def reactNativeArchitectures() { 87 | def value = project.getProperties().get("reactNativeArchitectures") 88 | return value ? value.split(",") : ["armeabi-v7a", "x86", "x86_64", "arm64-v8a"] 89 | } 90 | 91 | android { 92 | ndkVersion rootProject.ext.ndkVersion 93 | 94 | compileSdkVersion rootProject.ext.compileSdkVersion 95 | 96 | namespace "com.simpletoastexample" 97 | defaultConfig { 98 | applicationId "com.simpletoastexample" 99 | minSdkVersion rootProject.ext.minSdkVersion 100 | targetSdkVersion rootProject.ext.targetSdkVersion 101 | versionCode 1 102 | versionName "1.0" 103 | } 104 | 105 | splits { 106 | abi { 107 | reset() 108 | enable enableSeparateBuildPerCPUArchitecture 109 | universalApk false // If true, also generate a universal APK 110 | include (*reactNativeArchitectures()) 111 | } 112 | } 113 | signingConfigs { 114 | debug { 115 | storeFile file('debug.keystore') 116 | storePassword 'android' 117 | keyAlias 'androiddebugkey' 118 | keyPassword 'android' 119 | } 120 | } 121 | buildTypes { 122 | debug { 123 | signingConfig signingConfigs.debug 124 | } 125 | release { 126 | // Caution! In production, you need to generate your own keystore file. 127 | // see https://reactnative.dev/docs/signed-apk-android. 128 | signingConfig signingConfigs.debug 129 | minifyEnabled enableProguardInReleaseBuilds 130 | proguardFiles getDefaultProguardFile("proguard-android.txt"), "proguard-rules.pro" 131 | } 132 | } 133 | 134 | // applicationVariants are e.g. debug, release 135 | applicationVariants.all { variant -> 136 | variant.outputs.each { output -> 137 | // For each separate APK per architecture, set a unique version code as described here: 138 | // https://developer.android.com/studio/build/configure-apk-splits.html 139 | // Example: versionCode 1 will generate 1001 for armeabi-v7a, 1002 for x86, etc. 140 | def versionCodes = ["armeabi-v7a": 1, "x86": 2, "arm64-v8a": 3, "x86_64": 4] 141 | def abi = output.getFilter(OutputFile.ABI) 142 | if (abi != null) { // null for the universal-debug, universal-release variants 143 | output.versionCodeOverride = 144 | defaultConfig.versionCode * 1000 + versionCodes.get(abi) 145 | } 146 | 147 | } 148 | } 149 | } 150 | 151 | dependencies { 152 | // The version of react-native is set by the React Native Gradle Plugin 153 | implementation("com.facebook.react:react-android") 154 | 155 | implementation("androidx.swiperefreshlayout:swiperefreshlayout:1.0.0") 156 | 157 | debugImplementation("com.facebook.flipper:flipper:${FLIPPER_VERSION}") 158 | debugImplementation("com.facebook.flipper:flipper-network-plugin:${FLIPPER_VERSION}") { 159 | exclude group:'com.squareup.okhttp3', module:'okhttp' 160 | } 161 | 162 | debugImplementation("com.facebook.flipper:flipper-fresco-plugin:${FLIPPER_VERSION}") 163 | if (hermesEnabled.toBoolean()) { 164 | implementation("com.facebook.react:hermes-android") 165 | } else { 166 | implementation jscFlavor 167 | } 168 | } 169 | 170 | apply from: file("../../node_modules/@react-native-community/cli-platform-android/native_modules.gradle"); applyNativeModulesAppBuildGradle(project) 171 | -------------------------------------------------------------------------------- /example/android/app/debug.keystore: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vonovak/react-native-simple-toast/b87e23ffe1c3c298ec68bef0b11b66b49285cbfb/example/android/app/debug.keystore -------------------------------------------------------------------------------- /example/android/app/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # By default, the flags in this file are appended to flags specified 3 | # in /usr/local/Cellar/android-sdk/24.3.3/tools/proguard/proguard-android.txt 4 | # You can edit the include path and order by changing the proguardFiles 5 | # directive in build.gradle. 6 | # 7 | # For more details, see 8 | # http://developer.android.com/guide/developing/tools/proguard.html 9 | 10 | # Add any project specific keep options here: 11 | -------------------------------------------------------------------------------- /example/android/app/src/debug/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 11 | 12 | 13 | 14 | -------------------------------------------------------------------------------- /example/android/app/src/debug/java/com/simpletoastexample/ReactNativeFlipper.java: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright (c) Meta Platforms, Inc. and affiliates. 3 | * 4 | *

This source code is licensed under the MIT license found in the LICENSE file in the root 5 | * directory of this source tree. 6 | */ 7 | package com.simpletoastexample; 8 | 9 | import android.content.Context; 10 | import com.facebook.flipper.android.AndroidFlipperClient; 11 | import com.facebook.flipper.android.utils.FlipperUtils; 12 | import com.facebook.flipper.core.FlipperClient; 13 | import com.facebook.flipper.plugins.crashreporter.CrashReporterPlugin; 14 | import com.facebook.flipper.plugins.databases.DatabasesFlipperPlugin; 15 | import com.facebook.flipper.plugins.fresco.FrescoFlipperPlugin; 16 | import com.facebook.flipper.plugins.inspector.DescriptorMapping; 17 | import com.facebook.flipper.plugins.inspector.InspectorFlipperPlugin; 18 | import com.facebook.flipper.plugins.network.FlipperOkhttpInterceptor; 19 | import com.facebook.flipper.plugins.network.NetworkFlipperPlugin; 20 | import com.facebook.flipper.plugins.sharedpreferences.SharedPreferencesFlipperPlugin; 21 | import com.facebook.react.ReactInstanceEventListener; 22 | import com.facebook.react.ReactInstanceManager; 23 | import com.facebook.react.bridge.ReactContext; 24 | import com.facebook.react.modules.network.NetworkingModule; 25 | import okhttp3.OkHttpClient; 26 | 27 | /** 28 | * Class responsible of loading Flipper inside your React Native application. This is the debug 29 | * flavor of it. Here you can add your own plugins and customize the Flipper setup. 30 | */ 31 | public class ReactNativeFlipper { 32 | public static void initializeFlipper(Context context, ReactInstanceManager reactInstanceManager) { 33 | if (FlipperUtils.shouldEnableFlipper(context)) { 34 | final FlipperClient client = AndroidFlipperClient.getInstance(context); 35 | 36 | client.addPlugin(new InspectorFlipperPlugin(context, DescriptorMapping.withDefaults())); 37 | client.addPlugin(new DatabasesFlipperPlugin(context)); 38 | client.addPlugin(new SharedPreferencesFlipperPlugin(context)); 39 | client.addPlugin(CrashReporterPlugin.getInstance()); 40 | 41 | NetworkFlipperPlugin networkFlipperPlugin = new NetworkFlipperPlugin(); 42 | NetworkingModule.setCustomClientBuilder( 43 | new NetworkingModule.CustomClientBuilder() { 44 | @Override 45 | public void apply(OkHttpClient.Builder builder) { 46 | builder.addNetworkInterceptor(new FlipperOkhttpInterceptor(networkFlipperPlugin)); 47 | } 48 | }); 49 | client.addPlugin(networkFlipperPlugin); 50 | client.start(); 51 | 52 | // Fresco Plugin needs to ensure that ImagePipelineFactory is initialized 53 | // Hence we run if after all native modules have been initialized 54 | ReactContext reactContext = reactInstanceManager.getCurrentReactContext(); 55 | if (reactContext == null) { 56 | reactInstanceManager.addReactInstanceEventListener( 57 | new ReactInstanceEventListener() { 58 | @Override 59 | public void onReactContextInitialized(ReactContext reactContext) { 60 | reactInstanceManager.removeReactInstanceEventListener(this); 61 | reactContext.runOnNativeModulesQueueThread( 62 | new Runnable() { 63 | @Override 64 | public void run() { 65 | client.addPlugin(new FrescoFlipperPlugin()); 66 | } 67 | }); 68 | } 69 | }); 70 | } else { 71 | client.addPlugin(new FrescoFlipperPlugin()); 72 | } 73 | } 74 | } 75 | } 76 | -------------------------------------------------------------------------------- /example/android/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 12 | 19 | 20 | 21 | 22 | 23 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /example/android/app/src/main/java/com/simpletoastexample/MainActivity.java: -------------------------------------------------------------------------------- 1 | package com.simpletoastexample; 2 | 3 | import com.facebook.react.ReactActivity; 4 | import com.facebook.react.ReactActivityDelegate; 5 | import com.facebook.react.defaults.DefaultNewArchitectureEntryPoint; 6 | import com.facebook.react.defaults.DefaultReactActivityDelegate; 7 | 8 | public class MainActivity extends ReactActivity { 9 | 10 | /** 11 | * Returns the name of the main component registered from JavaScript. This is used to schedule 12 | * rendering of the component. 13 | */ 14 | @Override 15 | protected String getMainComponentName() { 16 | return "SimpleToastExample"; 17 | } 18 | 19 | /** 20 | * Returns the instance of the {@link ReactActivityDelegate}. Here we use a util class {@link 21 | * DefaultReactActivityDelegate} which allows you to easily enable Fabric and Concurrent React 22 | * (aka React 18) with two boolean flags. 23 | */ 24 | @Override 25 | protected ReactActivityDelegate createReactActivityDelegate() { 26 | return new DefaultReactActivityDelegate( 27 | this, 28 | getMainComponentName(), 29 | // If you opted-in for the New Architecture, we enable the Fabric Renderer. 30 | DefaultNewArchitectureEntryPoint.getFabricEnabled(), // fabricEnabled 31 | // If you opted-in for the New Architecture, we enable Concurrent React (i.e. React 18). 32 | DefaultNewArchitectureEntryPoint.getConcurrentReactEnabled() // concurrentRootEnabled 33 | ); 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /example/android/app/src/main/java/com/simpletoastexample/MainApplication.java: -------------------------------------------------------------------------------- 1 | package com.simpletoastexample; 2 | 3 | import android.app.Application; 4 | import com.facebook.react.PackageList; 5 | import com.facebook.react.ReactApplication; 6 | import com.facebook.react.ReactNativeHost; 7 | import com.facebook.react.ReactPackage; 8 | import com.facebook.react.defaults.DefaultNewArchitectureEntryPoint; 9 | import com.facebook.react.defaults.DefaultReactNativeHost; 10 | import com.facebook.soloader.SoLoader; 11 | import java.util.List; 12 | 13 | public class MainApplication extends Application implements ReactApplication { 14 | 15 | private final ReactNativeHost mReactNativeHost = 16 | new DefaultReactNativeHost(this) { 17 | @Override 18 | public boolean getUseDeveloperSupport() { 19 | return BuildConfig.DEBUG; 20 | } 21 | 22 | @Override 23 | protected List getPackages() { 24 | @SuppressWarnings("UnnecessaryLocalVariable") 25 | List packages = new PackageList(this).getPackages(); 26 | // Packages that cannot be autolinked yet can be added manually here, for example: 27 | // packages.add(new MyReactNativePackage()); 28 | return packages; 29 | } 30 | 31 | @Override 32 | protected String getJSMainModuleName() { 33 | return "index"; 34 | } 35 | 36 | @Override 37 | protected boolean isNewArchEnabled() { 38 | return BuildConfig.IS_NEW_ARCHITECTURE_ENABLED; 39 | } 40 | 41 | @Override 42 | protected Boolean isHermesEnabled() { 43 | return BuildConfig.IS_HERMES_ENABLED; 44 | } 45 | }; 46 | 47 | @Override 48 | public ReactNativeHost getReactNativeHost() { 49 | return mReactNativeHost; 50 | } 51 | 52 | @Override 53 | public void onCreate() { 54 | super.onCreate(); 55 | SoLoader.init(this, /* native exopackage */ false); 56 | if (BuildConfig.IS_NEW_ARCHITECTURE_ENABLED) { 57 | // If you opted-in for the New Architecture, we load the native entry point for this app. 58 | DefaultNewArchitectureEntryPoint.load(); 59 | } 60 | ReactNativeFlipper.initializeFlipper(this, getReactNativeHost().getReactInstanceManager()); 61 | } 62 | } 63 | -------------------------------------------------------------------------------- /example/android/app/src/main/res/drawable/rn_edit_text_material.xml: -------------------------------------------------------------------------------- 1 | 2 | 16 | 21 | 22 | 23 | 32 | 33 | 34 | 35 | 36 | 37 | -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vonovak/react-native-simple-toast/b87e23ffe1c3c298ec68bef0b11b66b49285cbfb/example/android/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vonovak/react-native-simple-toast/b87e23ffe1c3c298ec68bef0b11b66b49285cbfb/example/android/app/src/main/res/mipmap-hdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vonovak/react-native-simple-toast/b87e23ffe1c3c298ec68bef0b11b66b49285cbfb/example/android/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vonovak/react-native-simple-toast/b87e23ffe1c3c298ec68bef0b11b66b49285cbfb/example/android/app/src/main/res/mipmap-mdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vonovak/react-native-simple-toast/b87e23ffe1c3c298ec68bef0b11b66b49285cbfb/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vonovak/react-native-simple-toast/b87e23ffe1c3c298ec68bef0b11b66b49285cbfb/example/android/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vonovak/react-native-simple-toast/b87e23ffe1c3c298ec68bef0b11b66b49285cbfb/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vonovak/react-native-simple-toast/b87e23ffe1c3c298ec68bef0b11b66b49285cbfb/example/android/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vonovak/react-native-simple-toast/b87e23ffe1c3c298ec68bef0b11b66b49285cbfb/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vonovak/react-native-simple-toast/b87e23ffe1c3c298ec68bef0b11b66b49285cbfb/example/android/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /example/android/app/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | SimpleToastExample 3 | 4 | -------------------------------------------------------------------------------- /example/android/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 8 | 9 | 10 | -------------------------------------------------------------------------------- /example/android/app/src/release/java/com/simpletoastexample/ReactNativeFlipper.java: -------------------------------------------------------------------------------- 1 | /** 2 | * Copyright (c) Meta Platforms, Inc. and affiliates. 3 | * 4 | *

This source code is licensed under the MIT license found in the LICENSE file in the root 5 | * directory of this source tree. 6 | */ 7 | package com.simpletoastexample; 8 | 9 | import android.content.Context; 10 | import com.facebook.react.ReactInstanceManager; 11 | 12 | /** 13 | * Class responsible of loading Flipper inside your React Native application. This is the release 14 | * flavor of it so it's empty as we don't want to load Flipper. 15 | */ 16 | public class ReactNativeFlipper { 17 | public static void initializeFlipper(Context context, ReactInstanceManager reactInstanceManager) { 18 | // Do nothing as we don't want to initialize Flipper on Release. 19 | } 20 | } 21 | -------------------------------------------------------------------------------- /example/android/build.gradle: -------------------------------------------------------------------------------- 1 | // Top-level build file where you can add configuration options common to all sub-projects/modules. 2 | 3 | buildscript { 4 | ext { 5 | buildToolsVersion = "33.0.0" 6 | minSdkVersion = 21 7 | compileSdkVersion = 33 8 | targetSdkVersion = 33 9 | 10 | // We use NDK 23 which has both M1 support and is the side-by-side NDK version from AGP. 11 | ndkVersion = "23.1.7779620" 12 | } 13 | repositories { 14 | google() 15 | mavenCentral() 16 | } 17 | dependencies { 18 | classpath("com.android.tools.build:gradle:7.4.0-beta05") 19 | classpath("com.facebook.react:react-native-gradle-plugin") 20 | } 21 | } 22 | 23 | allprojects { 24 | repositories { 25 | maven { 26 | // All of React Native (JS, Obj-C sources, Android binaries) is installed from npm 27 | url("$rootDir/../node_modules/react-native/android") 28 | } 29 | maven { 30 | // Android JSC is installed from npm 31 | url("$rootDir/../node_modules/jsc-android/dist") 32 | } 33 | mavenCentral() 34 | google() 35 | maven { url 'https://www.jitpack.io' } 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /example/android/gradle.properties: -------------------------------------------------------------------------------- 1 | # Project-wide Gradle settings. 2 | 3 | # IDE (e.g. Android Studio) users: 4 | # Gradle settings configured through the IDE *will override* 5 | # any settings specified in this file. 6 | 7 | # For more details on how to configure your build environment visit 8 | # http://www.gradle.org/docs/current/userguide/build_environment.html 9 | 10 | # Specifies the JVM arguments used for the daemon process. 11 | # The setting is particularly useful for tweaking memory settings. 12 | # Default value: -Xmx512m -XX:MaxMetaspaceSize=256m 13 | org.gradle.jvmargs=-Xmx2048m -XX:MaxMetaspaceSize=512m 14 | 15 | # When configured, Gradle will run in incubating parallel mode. 16 | # This option should only be used with decoupled projects. More details, visit 17 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects 18 | # org.gradle.parallel=true 19 | 20 | # AndroidX package structure to make it clearer which packages are bundled with the 21 | # Android operating system, and which are packaged with your app's APK 22 | # https://developer.android.com/topic/libraries/support-library/androidx-rn 23 | android.useAndroidX=true 24 | # Automatically convert third-party libraries to use AndroidX 25 | android.enableJetifier=true 26 | 27 | # Version of flipper SDK to use with React Native 28 | FLIPPER_VERSION=0.125.0 29 | 30 | # Use this property to specify which architecture you want to build. 31 | # You can also override it from the CLI using 32 | # ./gradlew -PreactNativeArchitectures=x86_64 33 | reactNativeArchitectures=armeabi-v7a,arm64-v8a,x86,x86_64 34 | 35 | # Use this property to enable support to the new architecture. 36 | # This will allow you to use TurboModules and the Fabric render in 37 | # your application. You should enable this flag either if you want 38 | # to write custom TurboModules/Fabric components OR use libraries that 39 | # are providing them. 40 | newArchEnabled=true 41 | 42 | # Use this property to enable or disable the Hermes JS engine. 43 | # If set to false, you will be using JSC instead. 44 | hermesEnabled=true 45 | -------------------------------------------------------------------------------- /example/android/gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/vonovak/react-native-simple-toast/b87e23ffe1c3c298ec68bef0b11b66b49285cbfb/example/android/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /example/android/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | distributionBase=GRADLE_USER_HOME 2 | distributionPath=wrapper/dists 3 | distributionUrl=https\://services.gradle.org/distributions/gradle-7.5.1-all.zip 4 | zipStoreBase=GRADLE_USER_HOME 5 | zipStorePath=wrapper/dists 6 | -------------------------------------------------------------------------------- /example/android/gradlew: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | # 4 | # Copyright © 2015-2021 the original authors. 5 | # 6 | # Licensed under the Apache License, Version 2.0 (the "License"); 7 | # you may not use this file except in compliance with the License. 8 | # You may obtain a copy of the License at 9 | # 10 | # https://www.apache.org/licenses/LICENSE-2.0 11 | # 12 | # Unless required by applicable law or agreed to in writing, software 13 | # distributed under the License is distributed on an "AS IS" BASIS, 14 | # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 15 | # See the License for the specific language governing permissions and 16 | # limitations under the License. 17 | # 18 | 19 | ############################################################################## 20 | # 21 | # Gradle start up script for POSIX generated by Gradle. 22 | # 23 | # Important for running: 24 | # 25 | # (1) You need a POSIX-compliant shell to run this script. If your /bin/sh is 26 | # noncompliant, but you have some other compliant shell such as ksh or 27 | # bash, then to run this script, type that shell name before the whole 28 | # command line, like: 29 | # 30 | # ksh Gradle 31 | # 32 | # Busybox and similar reduced shells will NOT work, because this script 33 | # requires all of these POSIX shell features: 34 | # * functions; 35 | # * expansions «$var», «${var}», «${var:-default}», «${var+SET}», 36 | # «${var#prefix}», «${var%suffix}», and «$( cmd )»; 37 | # * compound commands having a testable exit status, especially «case»; 38 | # * various built-in commands including «command», «set», and «ulimit». 39 | # 40 | # Important for patching: 41 | # 42 | # (2) This script targets any POSIX shell, so it avoids extensions provided 43 | # by Bash, Ksh, etc; in particular arrays are avoided. 44 | # 45 | # The "traditional" practice of packing multiple parameters into a 46 | # space-separated string is a well documented source of bugs and security 47 | # problems, so this is (mostly) avoided, by progressively accumulating 48 | # options in "$@", and eventually passing that to Java. 49 | # 50 | # Where the inherited environment variables (DEFAULT_JVM_OPTS, JAVA_OPTS, 51 | # and GRADLE_OPTS) rely on word-splitting, this is performed explicitly; 52 | # see the in-line comments for details. 53 | # 54 | # There are tweaks for specific operating systems such as AIX, CygWin, 55 | # Darwin, MinGW, and NonStop. 56 | # 57 | # (3) This script is generated from the Groovy template 58 | # https://github.com/gradle/gradle/blob/master/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt 59 | # within the Gradle project. 60 | # 61 | # You can find Gradle at https://github.com/gradle/gradle/. 62 | # 63 | ############################################################################## 64 | 65 | # Attempt to set APP_HOME 66 | 67 | # Resolve links: $0 may be a link 68 | app_path=$0 69 | 70 | # Need this for daisy-chained symlinks. 71 | while 72 | APP_HOME=${app_path%"${app_path##*/}"} # leaves a trailing /; empty if no leading path 73 | [ -h "$app_path" ] 74 | do 75 | ls=$( ls -ld "$app_path" ) 76 | link=${ls#*' -> '} 77 | case $link in #( 78 | /*) app_path=$link ;; #( 79 | *) app_path=$APP_HOME$link ;; 80 | esac 81 | done 82 | 83 | APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit 84 | 85 | APP_NAME="Gradle" 86 | APP_BASE_NAME=${0##*/} 87 | 88 | # Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. 89 | DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"' 90 | 91 | # Use the maximum available, or set MAX_FD != -1 to use that value. 92 | MAX_FD=maximum 93 | 94 | warn () { 95 | echo "$*" 96 | } >&2 97 | 98 | die () { 99 | echo 100 | echo "$*" 101 | echo 102 | exit 1 103 | } >&2 104 | 105 | # OS specific support (must be 'true' or 'false'). 106 | cygwin=false 107 | msys=false 108 | darwin=false 109 | nonstop=false 110 | case "$( uname )" in #( 111 | CYGWIN* ) cygwin=true ;; #( 112 | Darwin* ) darwin=true ;; #( 113 | MSYS* | MINGW* ) msys=true ;; #( 114 | NONSTOP* ) nonstop=true ;; 115 | esac 116 | 117 | CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar 118 | 119 | 120 | # Determine the Java command to use to start the JVM. 121 | if [ -n "$JAVA_HOME" ] ; then 122 | if [ -x "$JAVA_HOME/jre/sh/java" ] ; then 123 | # IBM's JDK on AIX uses strange locations for the executables 124 | JAVACMD=$JAVA_HOME/jre/sh/java 125 | else 126 | JAVACMD=$JAVA_HOME/bin/java 127 | fi 128 | if [ ! -x "$JAVACMD" ] ; then 129 | die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME 130 | 131 | Please set the JAVA_HOME variable in your environment to match the 132 | location of your Java installation." 133 | fi 134 | else 135 | JAVACMD=java 136 | which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 137 | 138 | Please set the JAVA_HOME variable in your environment to match the 139 | location of your Java installation." 140 | fi 141 | 142 | # Increase the maximum file descriptors if we can. 143 | if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then 144 | case $MAX_FD in #( 145 | max*) 146 | MAX_FD=$( ulimit -H -n ) || 147 | warn "Could not query maximum file descriptor limit" 148 | esac 149 | case $MAX_FD in #( 150 | '' | soft) :;; #( 151 | *) 152 | ulimit -n "$MAX_FD" || 153 | warn "Could not set maximum file descriptor limit to $MAX_FD" 154 | esac 155 | fi 156 | 157 | # Collect all arguments for the java command, stacking in reverse order: 158 | # * args from the command line 159 | # * the main class name 160 | # * -classpath 161 | # * -D...appname settings 162 | # * --module-path (only if needed) 163 | # * DEFAULT_JVM_OPTS, JAVA_OPTS, and GRADLE_OPTS environment variables. 164 | 165 | # For Cygwin or MSYS, switch paths to Windows format before running java 166 | if "$cygwin" || "$msys" ; then 167 | APP_HOME=$( cygpath --path --mixed "$APP_HOME" ) 168 | CLASSPATH=$( cygpath --path --mixed "$CLASSPATH" ) 169 | 170 | JAVACMD=$( cygpath --unix "$JAVACMD" ) 171 | 172 | # Now convert the arguments - kludge to limit ourselves to /bin/sh 173 | for arg do 174 | if 175 | case $arg in #( 176 | -*) false ;; # don't mess with options #( 177 | /?*) t=${arg#/} t=/${t%%/*} # looks like a POSIX filepath 178 | [ -e "$t" ] ;; #( 179 | *) false ;; 180 | esac 181 | then 182 | arg=$( cygpath --path --ignore --mixed "$arg" ) 183 | fi 184 | # Roll the args list around exactly as many times as the number of 185 | # args, so each arg winds up back in the position where it started, but 186 | # possibly modified. 187 | # 188 | # NB: a `for` loop captures its iteration list before it begins, so 189 | # changing the positional parameters here affects neither the number of 190 | # iterations, nor the values presented in `arg`. 191 | shift # remove old arg 192 | set -- "$@" "$arg" # push replacement arg 193 | done 194 | fi 195 | 196 | # Collect all arguments for the java command; 197 | # * $DEFAULT_JVM_OPTS, $JAVA_OPTS, and $GRADLE_OPTS can contain fragments of 198 | # shell script including quotes and variable substitutions, so put them in 199 | # double quotes to make sure that they get re-expanded; and 200 | # * put everything else in single quotes, so that it's not re-expanded. 201 | 202 | set -- \ 203 | "-Dorg.gradle.appname=$APP_BASE_NAME" \ 204 | -classpath "$CLASSPATH" \ 205 | org.gradle.wrapper.GradleWrapperMain \ 206 | "$@" 207 | 208 | # Use "xargs" to parse quoted args. 209 | # 210 | # With -n1 it outputs one arg per line, with the quotes and backslashes removed. 211 | # 212 | # In Bash we could simply go: 213 | # 214 | # readarray ARGS < <( xargs -n1 <<<"$var" ) && 215 | # set -- "${ARGS[@]}" "$@" 216 | # 217 | # but POSIX shell has neither arrays nor command substitution, so instead we 218 | # post-process each arg (as a line of input to sed) to backslash-escape any 219 | # character that might be a shell metacharacter, then use eval to reverse 220 | # that process (while maintaining the separation between arguments), and wrap 221 | # the whole thing up as a single "set" statement. 222 | # 223 | # This will of course break if any of these variables contains a newline or 224 | # an unmatched quote. 225 | # 226 | 227 | eval "set -- $( 228 | printf '%s\n' "$DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS" | 229 | xargs -n1 | 230 | sed ' s~[^-[:alnum:]+,./:=@_]~\\&~g; ' | 231 | tr '\n' ' ' 232 | )" '"$@"' 233 | 234 | exec "$JAVACMD" "$@" 235 | -------------------------------------------------------------------------------- /example/android/gradlew.bat: -------------------------------------------------------------------------------- 1 | @rem 2 | @rem Copyright 2015 the original author or authors. 3 | @rem 4 | @rem Licensed under the Apache License, Version 2.0 (the "License"); 5 | @rem you may not use this file except in compliance with the License. 6 | @rem You may obtain a copy of the License at 7 | @rem 8 | @rem https://www.apache.org/licenses/LICENSE-2.0 9 | @rem 10 | @rem Unless required by applicable law or agreed to in writing, software 11 | @rem distributed under the License is distributed on an "AS IS" BASIS, 12 | @rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | @rem See the License for the specific language governing permissions and 14 | @rem limitations under the License. 15 | @rem 16 | 17 | @if "%DEBUG%" == "" @echo off 18 | @rem ########################################################################## 19 | @rem 20 | @rem Gradle startup script for Windows 21 | @rem 22 | @rem ########################################################################## 23 | 24 | @rem Set local scope for the variables with windows NT shell 25 | if "%OS%"=="Windows_NT" setlocal 26 | 27 | set DIRNAME=%~dp0 28 | if "%DIRNAME%" == "" set DIRNAME=. 29 | set APP_BASE_NAME=%~n0 30 | set APP_HOME=%DIRNAME% 31 | 32 | @rem Resolve any "." and ".." in APP_HOME to make it shorter. 33 | for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi 34 | 35 | @rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. 36 | set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m" 37 | 38 | @rem Find java.exe 39 | if defined JAVA_HOME goto findJavaFromJavaHome 40 | 41 | set JAVA_EXE=java.exe 42 | %JAVA_EXE% -version >NUL 2>&1 43 | if "%ERRORLEVEL%" == "0" goto execute 44 | 45 | echo. 46 | echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. 47 | echo. 48 | echo Please set the JAVA_HOME variable in your environment to match the 49 | echo location of your Java installation. 50 | 51 | goto fail 52 | 53 | :findJavaFromJavaHome 54 | set JAVA_HOME=%JAVA_HOME:"=% 55 | set JAVA_EXE=%JAVA_HOME%/bin/java.exe 56 | 57 | if exist "%JAVA_EXE%" goto execute 58 | 59 | echo. 60 | echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% 61 | echo. 62 | echo Please set the JAVA_HOME variable in your environment to match the 63 | echo location of your Java installation. 64 | 65 | goto fail 66 | 67 | :execute 68 | @rem Setup the command line 69 | 70 | set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar 71 | 72 | 73 | @rem Execute Gradle 74 | "%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %* 75 | 76 | :end 77 | @rem End local scope for the variables with windows NT shell 78 | if "%ERRORLEVEL%"=="0" goto mainEnd 79 | 80 | :fail 81 | rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of 82 | rem the _cmd.exe /c_ return code! 83 | if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1 84 | exit /b 1 85 | 86 | :mainEnd 87 | if "%OS%"=="Windows_NT" endlocal 88 | 89 | :omega 90 | -------------------------------------------------------------------------------- /example/android/settings.gradle: -------------------------------------------------------------------------------- 1 | rootProject.name = 'SimpleToastExample' 2 | apply from: file("../node_modules/@react-native-community/cli-platform-android/native_modules.gradle"); applyNativeModulesSettingsGradle(settings) 3 | include ':app' 4 | includeBuild('../node_modules/react-native-gradle-plugin') 5 | -------------------------------------------------------------------------------- /example/app.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "SimpleToastExample", 3 | "displayName": "SimpleToastExample" 4 | } -------------------------------------------------------------------------------- /example/babel.config.js: -------------------------------------------------------------------------------- 1 | const path = require('path'); 2 | const pak = require('../package.json'); 3 | 4 | module.exports = { 5 | presets: ['module:metro-react-native-babel-preset'], 6 | plugins: [ 7 | [ 8 | 'module-resolver', 9 | { 10 | extensions: ['.tsx', '.ts', '.js', '.json'], 11 | alias: { 12 | [pak.name]: path.join(__dirname, '..', pak.source), 13 | }, 14 | }, 15 | ], 16 | ], 17 | }; 18 | -------------------------------------------------------------------------------- /example/index.js: -------------------------------------------------------------------------------- 1 | import { AppRegistry } from 'react-native'; 2 | import App from './src/App'; 3 | import { name as appName } from './app.json'; 4 | 5 | AppRegistry.registerComponent(appName, () => App); 6 | -------------------------------------------------------------------------------- /example/ios/.xcode.env: -------------------------------------------------------------------------------- 1 | # This `.xcode.env` file is versioned and is used to source the environment 2 | # used when running script phases inside Xcode. 3 | # To customize your local environment, you can create an `.xcode.env.local` 4 | # file that is not versioned. 5 | 6 | # NODE_BINARY variable contains the PATH to the node executable. 7 | # 8 | # Customize the NODE_BINARY variable here. 9 | # For example, to use nvm with brew, add the following line 10 | # . "$(brew --prefix nvm)/nvm.sh" --no-use 11 | export NODE_BINARY=$(command -v node) 12 | -------------------------------------------------------------------------------- /example/ios/File.swift: -------------------------------------------------------------------------------- 1 | // 2 | // File.swift 3 | // SimpleToastExample 4 | // 5 | 6 | import Foundation 7 | -------------------------------------------------------------------------------- /example/ios/Podfile: -------------------------------------------------------------------------------- 1 | require_relative '../node_modules/react-native/scripts/react_native_pods' 2 | require_relative '../node_modules/react-native/scripts/native_modules' 3 | 4 | platform :ios, min_ios_version_supported 5 | prepare_react_native_project! 6 | 7 | # flipper_config = ENV['NO_FLIPPER'] == "1" ? FlipperConfiguration.disabled : FlipperConfiguration.enabled 8 | flipper_config = FlipperConfiguration.disabled 9 | 10 | linkage = ENV['USE_FRAMEWORKS'] 11 | if linkage != nil 12 | Pod::UI.puts "Configuring Pod with #{linkage}ally linked Frameworks".green 13 | use_frameworks! :linkage => linkage.to_sym 14 | end 15 | 16 | target 'SimpleToastExample' do 17 | config = use_native_modules! 18 | 19 | # Flags change depending on the env values. 20 | flags = get_default_flags() 21 | 22 | use_react_native!( 23 | :path => config[:reactNativePath], 24 | # Hermes is now enabled by default. Disable by setting this flag to false. 25 | # Upcoming versions of React Native may rely on get_default_flags(), but 26 | # we make it explicit here to aid in the React Native upgrade process. 27 | :hermes_enabled => flags[:hermes_enabled], 28 | :fabric_enabled => flags[:fabric_enabled], 29 | # Enables Flipper. 30 | # 31 | # Note that if you have use_frameworks! enabled, Flipper will not work and 32 | # you should disable the next line. 33 | :flipper_configuration => flipper_config, 34 | # An absolute path to your application root. 35 | :app_path => "#{Pod::Config.instance.installation_root}/.." 36 | ) 37 | 38 | target 'SimpleToastExampleTests' do 39 | inherit! :complete 40 | # Pods for testing 41 | end 42 | 43 | post_install do |installer| 44 | react_native_post_install( 45 | installer, 46 | # Set `mac_catalyst_enabled` to `true` in order to apply patches 47 | # necessary for Mac Catalyst builds 48 | :mac_catalyst_enabled => false 49 | ) 50 | __apply_Xcode_12_5_M1_post_install_workaround(installer) 51 | end 52 | end 53 | -------------------------------------------------------------------------------- /example/ios/Podfile.lock: -------------------------------------------------------------------------------- 1 | PODS: 2 | - boost (1.76.0) 3 | - DoubleConversion (1.1.6) 4 | - FBLazyVector (0.71.12) 5 | - FBReactNativeSpec (0.71.12): 6 | - RCT-Folly (= 2021.07.22.00) 7 | - RCTRequired (= 0.71.12) 8 | - RCTTypeSafety (= 0.71.12) 9 | - React-Core (= 0.71.12) 10 | - React-jsi (= 0.71.12) 11 | - ReactCommon/turbomodule/core (= 0.71.12) 12 | - fmt (6.2.1) 13 | - glog (0.3.5) 14 | - hermes-engine (0.71.12): 15 | - hermes-engine/Pre-built (= 0.71.12) 16 | - hermes-engine/Pre-built (0.71.12) 17 | - libevent (2.1.12) 18 | - RCT-Folly (2021.07.22.00): 19 | - boost 20 | - DoubleConversion 21 | - fmt (~> 6.2.1) 22 | - glog 23 | - RCT-Folly/Default (= 2021.07.22.00) 24 | - RCT-Folly/Default (2021.07.22.00): 25 | - boost 26 | - DoubleConversion 27 | - fmt (~> 6.2.1) 28 | - glog 29 | - RCT-Folly/Futures (2021.07.22.00): 30 | - boost 31 | - DoubleConversion 32 | - fmt (~> 6.2.1) 33 | - glog 34 | - libevent 35 | - RCTRequired (0.71.12) 36 | - RCTTypeSafety (0.71.12): 37 | - FBLazyVector (= 0.71.12) 38 | - RCTRequired (= 0.71.12) 39 | - React-Core (= 0.71.12) 40 | - React (0.71.12): 41 | - React-Core (= 0.71.12) 42 | - React-Core/DevSupport (= 0.71.12) 43 | - React-Core/RCTWebSocket (= 0.71.12) 44 | - React-RCTActionSheet (= 0.71.12) 45 | - React-RCTAnimation (= 0.71.12) 46 | - React-RCTBlob (= 0.71.12) 47 | - React-RCTImage (= 0.71.12) 48 | - React-RCTLinking (= 0.71.12) 49 | - React-RCTNetwork (= 0.71.12) 50 | - React-RCTSettings (= 0.71.12) 51 | - React-RCTText (= 0.71.12) 52 | - React-RCTVibration (= 0.71.12) 53 | - React-callinvoker (0.71.12) 54 | - React-Codegen (0.71.12): 55 | - FBReactNativeSpec 56 | - hermes-engine 57 | - RCT-Folly 58 | - RCTRequired 59 | - RCTTypeSafety 60 | - React-Core 61 | - React-jsi 62 | - React-jsiexecutor 63 | - ReactCommon/turbomodule/bridging 64 | - ReactCommon/turbomodule/core 65 | - React-Core (0.71.12): 66 | - glog 67 | - hermes-engine 68 | - RCT-Folly (= 2021.07.22.00) 69 | - React-Core/Default (= 0.71.12) 70 | - React-cxxreact (= 0.71.12) 71 | - React-hermes 72 | - React-jsi (= 0.71.12) 73 | - React-jsiexecutor (= 0.71.12) 74 | - React-perflogger (= 0.71.12) 75 | - Yoga 76 | - React-Core/CoreModulesHeaders (0.71.12): 77 | - glog 78 | - hermes-engine 79 | - RCT-Folly (= 2021.07.22.00) 80 | - React-Core/Default 81 | - React-cxxreact (= 0.71.12) 82 | - React-hermes 83 | - React-jsi (= 0.71.12) 84 | - React-jsiexecutor (= 0.71.12) 85 | - React-perflogger (= 0.71.12) 86 | - Yoga 87 | - React-Core/Default (0.71.12): 88 | - glog 89 | - hermes-engine 90 | - RCT-Folly (= 2021.07.22.00) 91 | - React-cxxreact (= 0.71.12) 92 | - React-hermes 93 | - React-jsi (= 0.71.12) 94 | - React-jsiexecutor (= 0.71.12) 95 | - React-perflogger (= 0.71.12) 96 | - Yoga 97 | - React-Core/DevSupport (0.71.12): 98 | - glog 99 | - hermes-engine 100 | - RCT-Folly (= 2021.07.22.00) 101 | - React-Core/Default (= 0.71.12) 102 | - React-Core/RCTWebSocket (= 0.71.12) 103 | - React-cxxreact (= 0.71.12) 104 | - React-hermes 105 | - React-jsi (= 0.71.12) 106 | - React-jsiexecutor (= 0.71.12) 107 | - React-jsinspector (= 0.71.12) 108 | - React-perflogger (= 0.71.12) 109 | - Yoga 110 | - React-Core/RCTActionSheetHeaders (0.71.12): 111 | - glog 112 | - hermes-engine 113 | - RCT-Folly (= 2021.07.22.00) 114 | - React-Core/Default 115 | - React-cxxreact (= 0.71.12) 116 | - React-hermes 117 | - React-jsi (= 0.71.12) 118 | - React-jsiexecutor (= 0.71.12) 119 | - React-perflogger (= 0.71.12) 120 | - Yoga 121 | - React-Core/RCTAnimationHeaders (0.71.12): 122 | - glog 123 | - hermes-engine 124 | - RCT-Folly (= 2021.07.22.00) 125 | - React-Core/Default 126 | - React-cxxreact (= 0.71.12) 127 | - React-hermes 128 | - React-jsi (= 0.71.12) 129 | - React-jsiexecutor (= 0.71.12) 130 | - React-perflogger (= 0.71.12) 131 | - Yoga 132 | - React-Core/RCTBlobHeaders (0.71.12): 133 | - glog 134 | - hermes-engine 135 | - RCT-Folly (= 2021.07.22.00) 136 | - React-Core/Default 137 | - React-cxxreact (= 0.71.12) 138 | - React-hermes 139 | - React-jsi (= 0.71.12) 140 | - React-jsiexecutor (= 0.71.12) 141 | - React-perflogger (= 0.71.12) 142 | - Yoga 143 | - React-Core/RCTImageHeaders (0.71.12): 144 | - glog 145 | - hermes-engine 146 | - RCT-Folly (= 2021.07.22.00) 147 | - React-Core/Default 148 | - React-cxxreact (= 0.71.12) 149 | - React-hermes 150 | - React-jsi (= 0.71.12) 151 | - React-jsiexecutor (= 0.71.12) 152 | - React-perflogger (= 0.71.12) 153 | - Yoga 154 | - React-Core/RCTLinkingHeaders (0.71.12): 155 | - glog 156 | - hermes-engine 157 | - RCT-Folly (= 2021.07.22.00) 158 | - React-Core/Default 159 | - React-cxxreact (= 0.71.12) 160 | - React-hermes 161 | - React-jsi (= 0.71.12) 162 | - React-jsiexecutor (= 0.71.12) 163 | - React-perflogger (= 0.71.12) 164 | - Yoga 165 | - React-Core/RCTNetworkHeaders (0.71.12): 166 | - glog 167 | - hermes-engine 168 | - RCT-Folly (= 2021.07.22.00) 169 | - React-Core/Default 170 | - React-cxxreact (= 0.71.12) 171 | - React-hermes 172 | - React-jsi (= 0.71.12) 173 | - React-jsiexecutor (= 0.71.12) 174 | - React-perflogger (= 0.71.12) 175 | - Yoga 176 | - React-Core/RCTSettingsHeaders (0.71.12): 177 | - glog 178 | - hermes-engine 179 | - RCT-Folly (= 2021.07.22.00) 180 | - React-Core/Default 181 | - React-cxxreact (= 0.71.12) 182 | - React-hermes 183 | - React-jsi (= 0.71.12) 184 | - React-jsiexecutor (= 0.71.12) 185 | - React-perflogger (= 0.71.12) 186 | - Yoga 187 | - React-Core/RCTTextHeaders (0.71.12): 188 | - glog 189 | - hermes-engine 190 | - RCT-Folly (= 2021.07.22.00) 191 | - React-Core/Default 192 | - React-cxxreact (= 0.71.12) 193 | - React-hermes 194 | - React-jsi (= 0.71.12) 195 | - React-jsiexecutor (= 0.71.12) 196 | - React-perflogger (= 0.71.12) 197 | - Yoga 198 | - React-Core/RCTVibrationHeaders (0.71.12): 199 | - glog 200 | - hermes-engine 201 | - RCT-Folly (= 2021.07.22.00) 202 | - React-Core/Default 203 | - React-cxxreact (= 0.71.12) 204 | - React-hermes 205 | - React-jsi (= 0.71.12) 206 | - React-jsiexecutor (= 0.71.12) 207 | - React-perflogger (= 0.71.12) 208 | - Yoga 209 | - React-Core/RCTWebSocket (0.71.12): 210 | - glog 211 | - hermes-engine 212 | - RCT-Folly (= 2021.07.22.00) 213 | - React-Core/Default (= 0.71.12) 214 | - React-cxxreact (= 0.71.12) 215 | - React-hermes 216 | - React-jsi (= 0.71.12) 217 | - React-jsiexecutor (= 0.71.12) 218 | - React-perflogger (= 0.71.12) 219 | - Yoga 220 | - React-CoreModules (0.71.12): 221 | - RCT-Folly (= 2021.07.22.00) 222 | - RCTTypeSafety (= 0.71.12) 223 | - React-Codegen (= 0.71.12) 224 | - React-Core/CoreModulesHeaders (= 0.71.12) 225 | - React-jsi (= 0.71.12) 226 | - React-RCTBlob 227 | - React-RCTImage (= 0.71.12) 228 | - ReactCommon/turbomodule/core (= 0.71.12) 229 | - React-cxxreact (0.71.12): 230 | - boost (= 1.76.0) 231 | - DoubleConversion 232 | - glog 233 | - hermes-engine 234 | - RCT-Folly (= 2021.07.22.00) 235 | - React-callinvoker (= 0.71.12) 236 | - React-jsi (= 0.71.12) 237 | - React-jsinspector (= 0.71.12) 238 | - React-logger (= 0.71.12) 239 | - React-perflogger (= 0.71.12) 240 | - React-runtimeexecutor (= 0.71.12) 241 | - React-hermes (0.71.12): 242 | - DoubleConversion 243 | - glog 244 | - hermes-engine 245 | - RCT-Folly (= 2021.07.22.00) 246 | - RCT-Folly/Futures (= 2021.07.22.00) 247 | - React-cxxreact (= 0.71.12) 248 | - React-jsi 249 | - React-jsiexecutor (= 0.71.12) 250 | - React-jsinspector (= 0.71.12) 251 | - React-perflogger (= 0.71.12) 252 | - React-jsi (0.71.12): 253 | - boost (= 1.76.0) 254 | - DoubleConversion 255 | - glog 256 | - hermes-engine 257 | - RCT-Folly (= 2021.07.22.00) 258 | - React-jsiexecutor (0.71.12): 259 | - DoubleConversion 260 | - glog 261 | - hermes-engine 262 | - RCT-Folly (= 2021.07.22.00) 263 | - React-cxxreact (= 0.71.12) 264 | - React-jsi (= 0.71.12) 265 | - React-perflogger (= 0.71.12) 266 | - React-jsinspector (0.71.12) 267 | - React-logger (0.71.12): 268 | - glog 269 | - react-native-simple-toast (3.0.1): 270 | - React-Core 271 | - Toast (~> 4) 272 | - React-perflogger (0.71.12) 273 | - React-RCTActionSheet (0.71.12): 274 | - React-Core/RCTActionSheetHeaders (= 0.71.12) 275 | - React-RCTAnimation (0.71.12): 276 | - RCT-Folly (= 2021.07.22.00) 277 | - RCTTypeSafety (= 0.71.12) 278 | - React-Codegen (= 0.71.12) 279 | - React-Core/RCTAnimationHeaders (= 0.71.12) 280 | - React-jsi (= 0.71.12) 281 | - ReactCommon/turbomodule/core (= 0.71.12) 282 | - React-RCTAppDelegate (0.71.12): 283 | - RCT-Folly 284 | - RCTRequired 285 | - RCTTypeSafety 286 | - React-Core 287 | - ReactCommon/turbomodule/core 288 | - React-RCTBlob (0.71.12): 289 | - hermes-engine 290 | - RCT-Folly (= 2021.07.22.00) 291 | - React-Codegen (= 0.71.12) 292 | - React-Core/RCTBlobHeaders (= 0.71.12) 293 | - React-Core/RCTWebSocket (= 0.71.12) 294 | - React-jsi (= 0.71.12) 295 | - React-RCTNetwork (= 0.71.12) 296 | - ReactCommon/turbomodule/core (= 0.71.12) 297 | - React-RCTImage (0.71.12): 298 | - RCT-Folly (= 2021.07.22.00) 299 | - RCTTypeSafety (= 0.71.12) 300 | - React-Codegen (= 0.71.12) 301 | - React-Core/RCTImageHeaders (= 0.71.12) 302 | - React-jsi (= 0.71.12) 303 | - React-RCTNetwork (= 0.71.12) 304 | - ReactCommon/turbomodule/core (= 0.71.12) 305 | - React-RCTLinking (0.71.12): 306 | - React-Codegen (= 0.71.12) 307 | - React-Core/RCTLinkingHeaders (= 0.71.12) 308 | - React-jsi (= 0.71.12) 309 | - ReactCommon/turbomodule/core (= 0.71.12) 310 | - React-RCTNetwork (0.71.12): 311 | - RCT-Folly (= 2021.07.22.00) 312 | - RCTTypeSafety (= 0.71.12) 313 | - React-Codegen (= 0.71.12) 314 | - React-Core/RCTNetworkHeaders (= 0.71.12) 315 | - React-jsi (= 0.71.12) 316 | - ReactCommon/turbomodule/core (= 0.71.12) 317 | - React-RCTSettings (0.71.12): 318 | - RCT-Folly (= 2021.07.22.00) 319 | - RCTTypeSafety (= 0.71.12) 320 | - React-Codegen (= 0.71.12) 321 | - React-Core/RCTSettingsHeaders (= 0.71.12) 322 | - React-jsi (= 0.71.12) 323 | - ReactCommon/turbomodule/core (= 0.71.12) 324 | - React-RCTText (0.71.12): 325 | - React-Core/RCTTextHeaders (= 0.71.12) 326 | - React-RCTVibration (0.71.12): 327 | - RCT-Folly (= 2021.07.22.00) 328 | - React-Codegen (= 0.71.12) 329 | - React-Core/RCTVibrationHeaders (= 0.71.12) 330 | - React-jsi (= 0.71.12) 331 | - ReactCommon/turbomodule/core (= 0.71.12) 332 | - React-runtimeexecutor (0.71.12): 333 | - React-jsi (= 0.71.12) 334 | - ReactCommon/turbomodule/bridging (0.71.12): 335 | - DoubleConversion 336 | - glog 337 | - hermes-engine 338 | - RCT-Folly (= 2021.07.22.00) 339 | - React-callinvoker (= 0.71.12) 340 | - React-Core (= 0.71.12) 341 | - React-cxxreact (= 0.71.12) 342 | - React-jsi (= 0.71.12) 343 | - React-logger (= 0.71.12) 344 | - React-perflogger (= 0.71.12) 345 | - ReactCommon/turbomodule/core (0.71.12): 346 | - DoubleConversion 347 | - glog 348 | - hermes-engine 349 | - RCT-Folly (= 2021.07.22.00) 350 | - React-callinvoker (= 0.71.12) 351 | - React-Core (= 0.71.12) 352 | - React-cxxreact (= 0.71.12) 353 | - React-jsi (= 0.71.12) 354 | - React-logger (= 0.71.12) 355 | - React-perflogger (= 0.71.12) 356 | - Toast (4.0.0) 357 | - Yoga (1.14.0) 358 | 359 | DEPENDENCIES: 360 | - boost (from `../node_modules/react-native/third-party-podspecs/boost.podspec`) 361 | - DoubleConversion (from `../node_modules/react-native/third-party-podspecs/DoubleConversion.podspec`) 362 | - FBLazyVector (from `../node_modules/react-native/Libraries/FBLazyVector`) 363 | - FBReactNativeSpec (from `../node_modules/react-native/React/FBReactNativeSpec`) 364 | - glog (from `../node_modules/react-native/third-party-podspecs/glog.podspec`) 365 | - hermes-engine (from `../node_modules/react-native/sdks/hermes-engine/hermes-engine.podspec`) 366 | - libevent (~> 2.1.12) 367 | - RCT-Folly (from `../node_modules/react-native/third-party-podspecs/RCT-Folly.podspec`) 368 | - RCTRequired (from `../node_modules/react-native/Libraries/RCTRequired`) 369 | - RCTTypeSafety (from `../node_modules/react-native/Libraries/TypeSafety`) 370 | - React (from `../node_modules/react-native/`) 371 | - React-callinvoker (from `../node_modules/react-native/ReactCommon/callinvoker`) 372 | - React-Codegen (from `build/generated/ios`) 373 | - React-Core (from `../node_modules/react-native/`) 374 | - React-Core/RCTWebSocket (from `../node_modules/react-native/`) 375 | - React-CoreModules (from `../node_modules/react-native/React/CoreModules`) 376 | - React-cxxreact (from `../node_modules/react-native/ReactCommon/cxxreact`) 377 | - React-hermes (from `../node_modules/react-native/ReactCommon/hermes`) 378 | - React-jsi (from `../node_modules/react-native/ReactCommon/jsi`) 379 | - React-jsiexecutor (from `../node_modules/react-native/ReactCommon/jsiexecutor`) 380 | - React-jsinspector (from `../node_modules/react-native/ReactCommon/jsinspector`) 381 | - React-logger (from `../node_modules/react-native/ReactCommon/logger`) 382 | - react-native-simple-toast (from `../..`) 383 | - React-perflogger (from `../node_modules/react-native/ReactCommon/reactperflogger`) 384 | - React-RCTActionSheet (from `../node_modules/react-native/Libraries/ActionSheetIOS`) 385 | - React-RCTAnimation (from `../node_modules/react-native/Libraries/NativeAnimation`) 386 | - React-RCTAppDelegate (from `../node_modules/react-native/Libraries/AppDelegate`) 387 | - React-RCTBlob (from `../node_modules/react-native/Libraries/Blob`) 388 | - React-RCTImage (from `../node_modules/react-native/Libraries/Image`) 389 | - React-RCTLinking (from `../node_modules/react-native/Libraries/LinkingIOS`) 390 | - React-RCTNetwork (from `../node_modules/react-native/Libraries/Network`) 391 | - React-RCTSettings (from `../node_modules/react-native/Libraries/Settings`) 392 | - React-RCTText (from `../node_modules/react-native/Libraries/Text`) 393 | - React-RCTVibration (from `../node_modules/react-native/Libraries/Vibration`) 394 | - React-runtimeexecutor (from `../node_modules/react-native/ReactCommon/runtimeexecutor`) 395 | - ReactCommon/turbomodule/core (from `../node_modules/react-native/ReactCommon`) 396 | - Yoga (from `../node_modules/react-native/ReactCommon/yoga`) 397 | 398 | SPEC REPOS: 399 | trunk: 400 | - fmt 401 | - libevent 402 | - Toast 403 | 404 | EXTERNAL SOURCES: 405 | boost: 406 | :podspec: "../node_modules/react-native/third-party-podspecs/boost.podspec" 407 | DoubleConversion: 408 | :podspec: "../node_modules/react-native/third-party-podspecs/DoubleConversion.podspec" 409 | FBLazyVector: 410 | :path: "../node_modules/react-native/Libraries/FBLazyVector" 411 | FBReactNativeSpec: 412 | :path: "../node_modules/react-native/React/FBReactNativeSpec" 413 | glog: 414 | :podspec: "../node_modules/react-native/third-party-podspecs/glog.podspec" 415 | hermes-engine: 416 | :podspec: "../node_modules/react-native/sdks/hermes-engine/hermes-engine.podspec" 417 | RCT-Folly: 418 | :podspec: "../node_modules/react-native/third-party-podspecs/RCT-Folly.podspec" 419 | RCTRequired: 420 | :path: "../node_modules/react-native/Libraries/RCTRequired" 421 | RCTTypeSafety: 422 | :path: "../node_modules/react-native/Libraries/TypeSafety" 423 | React: 424 | :path: "../node_modules/react-native/" 425 | React-callinvoker: 426 | :path: "../node_modules/react-native/ReactCommon/callinvoker" 427 | React-Codegen: 428 | :path: build/generated/ios 429 | React-Core: 430 | :path: "../node_modules/react-native/" 431 | React-CoreModules: 432 | :path: "../node_modules/react-native/React/CoreModules" 433 | React-cxxreact: 434 | :path: "../node_modules/react-native/ReactCommon/cxxreact" 435 | React-hermes: 436 | :path: "../node_modules/react-native/ReactCommon/hermes" 437 | React-jsi: 438 | :path: "../node_modules/react-native/ReactCommon/jsi" 439 | React-jsiexecutor: 440 | :path: "../node_modules/react-native/ReactCommon/jsiexecutor" 441 | React-jsinspector: 442 | :path: "../node_modules/react-native/ReactCommon/jsinspector" 443 | React-logger: 444 | :path: "../node_modules/react-native/ReactCommon/logger" 445 | react-native-simple-toast: 446 | :path: "../.." 447 | React-perflogger: 448 | :path: "../node_modules/react-native/ReactCommon/reactperflogger" 449 | React-RCTActionSheet: 450 | :path: "../node_modules/react-native/Libraries/ActionSheetIOS" 451 | React-RCTAnimation: 452 | :path: "../node_modules/react-native/Libraries/NativeAnimation" 453 | React-RCTAppDelegate: 454 | :path: "../node_modules/react-native/Libraries/AppDelegate" 455 | React-RCTBlob: 456 | :path: "../node_modules/react-native/Libraries/Blob" 457 | React-RCTImage: 458 | :path: "../node_modules/react-native/Libraries/Image" 459 | React-RCTLinking: 460 | :path: "../node_modules/react-native/Libraries/LinkingIOS" 461 | React-RCTNetwork: 462 | :path: "../node_modules/react-native/Libraries/Network" 463 | React-RCTSettings: 464 | :path: "../node_modules/react-native/Libraries/Settings" 465 | React-RCTText: 466 | :path: "../node_modules/react-native/Libraries/Text" 467 | React-RCTVibration: 468 | :path: "../node_modules/react-native/Libraries/Vibration" 469 | React-runtimeexecutor: 470 | :path: "../node_modules/react-native/ReactCommon/runtimeexecutor" 471 | ReactCommon: 472 | :path: "../node_modules/react-native/ReactCommon" 473 | Yoga: 474 | :path: "../node_modules/react-native/ReactCommon/yoga" 475 | 476 | SPEC CHECKSUMS: 477 | boost: 57d2868c099736d80fcd648bf211b4431e51a558 478 | DoubleConversion: 5189b271737e1565bdce30deb4a08d647e3f5f54 479 | FBLazyVector: 4eb7ee83e8d0ad7e20a829485295ff48823c4e4c 480 | FBReactNativeSpec: b24809f97ae83c786928d56b732957195b4fa390 481 | fmt: ff9d55029c625d3757ed641535fd4a75fedc7ce9 482 | glog: 04b94705f318337d7ead9e6d17c019bd9b1f6b1b 483 | hermes-engine: b60ebc812e0179a612d8146ac54730d533c804a2 484 | libevent: 4049cae6c81cdb3654a443be001fb9bdceff7913 485 | RCT-Folly: 424b8c9a7a0b9ab2886ffe9c3b041ef628fd4fb1 486 | RCTRequired: 4db5e3e18b906377a502da5b358ff159ba4783ed 487 | RCTTypeSafety: 6c1a8aed043050de0d537336c95cd1be7b66c272 488 | React: 214e77358d860a3ed707fede9088e7c00663a087 489 | React-callinvoker: 8fc1c79c26fbcadce2a5d4a3cb4b2ced2dec3436 490 | React-Codegen: 1517e1a59c594e6b5661d3d054209e838baa4fa7 491 | React-Core: ea541085ca5be10b2be289c7d82eba368b5c4900 492 | React-CoreModules: d9680e1d551eef1dd764df736a473cf25f701070 493 | React-cxxreact: 0792e80e291d086b2cf588410f6bc6e752bc1d83 494 | React-hermes: 0b1bba58112cb7421f1166d527a1a05489f48dbc 495 | React-jsi: 1e41088515c4273ef5b118575337df4671851430 496 | React-jsiexecutor: 509cd947c28834614808ce056ee8eb700a0662aa 497 | React-jsinspector: ec4dcbfb1f4e72f04f826a0301eceee5fa7ca540 498 | React-logger: 35538accacf2583693fbc3ee8b53e69a1776fcee 499 | react-native-simple-toast: 0c7d14bcad288b5b83ae4b0eea65651b4ca829b0 500 | React-perflogger: 75b0e25075c67565a830985f3c373e2eae5389e0 501 | React-RCTActionSheet: a0c3e916b327e297d124d9ebe8b0c721840ee04d 502 | React-RCTAnimation: 3da7025801d7bf0f8cfd94574d6278d5b82a8b88 503 | React-RCTAppDelegate: f74a567e0bc905aaff66d47ab30e6548f727549c 504 | React-RCTBlob: 53252ebabe7777fd1c440a34546c64e16b162908 505 | React-RCTImage: e230761bd34d71362dd8b3d51b5cd72674935aa0 506 | React-RCTLinking: 3294b1b540005628168e5a341963b0eddc3932e8 507 | React-RCTNetwork: 00c6b2215e54a9fb015c53a5e02b0a852dbb8568 508 | React-RCTSettings: 2e7e4964f45e9b24c6c32ad30b6ab2ef4a7e2ffc 509 | React-RCTText: a9c712b13cab90e1432e0ad113edc8bdbc691248 510 | React-RCTVibration: a283fefb8cc29d9740a7ff2e87f72ad10f25a433 511 | React-runtimeexecutor: 7902246857a4ead4166869e6c42d4df329ff721d 512 | ReactCommon: a6d1c76b9e10b439e41db225263341240e1cda9f 513 | Toast: 91b396c56ee72a5790816f40d3a94dd357abc196 514 | Yoga: 39310a10944fc864a7550700de349183450f8aaa 515 | 516 | PODFILE CHECKSUM: bd4b76d1b6e4056b6917238d3d216ce617aca0e8 517 | 518 | COCOAPODS: 1.12.1 519 | -------------------------------------------------------------------------------- /example/ios/SimpleToastExample-Bridging-Header.h: -------------------------------------------------------------------------------- 1 | // 2 | // Use this file to import your target's public headers that you would like to expose to Swift. 3 | // 4 | -------------------------------------------------------------------------------- /example/ios/SimpleToastExample.xcodeproj/project.pbxproj: -------------------------------------------------------------------------------- 1 | // !$*UTF8*$! 2 | { 3 | archiveVersion = 1; 4 | classes = { 5 | }; 6 | objectVersion = 54; 7 | objects = { 8 | 9 | /* Begin PBXBuildFile section */ 10 | 00E356F31AD99517003FC87E /* SimpleToastExampleTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 00E356F21AD99517003FC87E /* SimpleToastExampleTests.m */; }; 11 | 0C80B921A6F3F58F76C31292 /* libPods-SimpleToastExample.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 5DCACB8F33CDC322A6C60F78 /* libPods-SimpleToastExample.a */; }; 12 | 13B07FBC1A68108700A75B9A /* AppDelegate.mm in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB01A68108700A75B9A /* AppDelegate.mm */; }; 13 | 13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 13B07FB51A68108700A75B9A /* Images.xcassets */; }; 14 | 13B07FC11A68108700A75B9A /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 13B07FB71A68108700A75B9A /* main.m */; }; 15 | 7699B88040F8A987B510C191 /* libPods-SimpleToastExample-SimpleToastExampleTests.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 19F6CBCC0A4E27FBF8BF4A61 /* libPods-SimpleToastExample-SimpleToastExampleTests.a */; }; 16 | 81AB9BB82411601600AC10FF /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 81AB9BB72411601600AC10FF /* LaunchScreen.storyboard */; }; 17 | /* End PBXBuildFile section */ 18 | 19 | /* Begin PBXContainerItemProxy section */ 20 | 00E356F41AD99517003FC87E /* PBXContainerItemProxy */ = { 21 | isa = PBXContainerItemProxy; 22 | containerPortal = 83CBB9F71A601CBA00E9B192 /* Project object */; 23 | proxyType = 1; 24 | remoteGlobalIDString = 13B07F861A680F5B00A75B9A; 25 | remoteInfo = SimpleToastExample; 26 | }; 27 | /* End PBXContainerItemProxy section */ 28 | 29 | /* Begin PBXFileReference section */ 30 | 00E356EE1AD99517003FC87E /* SimpleToastExampleTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = SimpleToastExampleTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; }; 31 | 00E356F11AD99517003FC87E /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; }; 32 | 00E356F21AD99517003FC87E /* SimpleToastExampleTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = SimpleToastExampleTests.m; sourceTree = ""; }; 33 | 13B07F961A680F5B00A75B9A /* SimpleToastExample.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = SimpleToastExample.app; sourceTree = BUILT_PRODUCTS_DIR; }; 34 | 13B07FAF1A68108700A75B9A /* AppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = AppDelegate.h; path = SimpleToastExample/AppDelegate.h; sourceTree = ""; }; 35 | 13B07FB01A68108700A75B9A /* AppDelegate.mm */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.objcpp; name = AppDelegate.mm; path = SimpleToastExample/AppDelegate.mm; sourceTree = ""; }; 36 | 13B07FB51A68108700A75B9A /* Images.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; name = Images.xcassets; path = SimpleToastExample/Images.xcassets; sourceTree = ""; }; 37 | 13B07FB61A68108700A75B9A /* Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = Info.plist; path = SimpleToastExample/Info.plist; sourceTree = ""; }; 38 | 13B07FB71A68108700A75B9A /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = main.m; path = SimpleToastExample/main.m; sourceTree = ""; }; 39 | 19F6CBCC0A4E27FBF8BF4A61 /* libPods-SimpleToastExample-SimpleToastExampleTests.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-SimpleToastExample-SimpleToastExampleTests.a"; sourceTree = BUILT_PRODUCTS_DIR; }; 40 | 3B4392A12AC88292D35C810B /* Pods-SimpleToastExample.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-SimpleToastExample.debug.xcconfig"; path = "Target Support Files/Pods-SimpleToastExample/Pods-SimpleToastExample.debug.xcconfig"; sourceTree = ""; }; 41 | 5709B34CF0A7D63546082F79 /* Pods-SimpleToastExample.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-SimpleToastExample.release.xcconfig"; path = "Target Support Files/Pods-SimpleToastExample/Pods-SimpleToastExample.release.xcconfig"; sourceTree = ""; }; 42 | 5B7EB9410499542E8C5724F5 /* Pods-SimpleToastExample-SimpleToastExampleTests.debug.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-SimpleToastExample-SimpleToastExampleTests.debug.xcconfig"; path = "Target Support Files/Pods-SimpleToastExample-SimpleToastExampleTests/Pods-SimpleToastExample-SimpleToastExampleTests.debug.xcconfig"; sourceTree = ""; }; 43 | 5DCACB8F33CDC322A6C60F78 /* libPods-SimpleToastExample.a */ = {isa = PBXFileReference; explicitFileType = archive.ar; includeInIndex = 0; path = "libPods-SimpleToastExample.a"; sourceTree = BUILT_PRODUCTS_DIR; }; 44 | 81AB9BB72411601600AC10FF /* LaunchScreen.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; name = LaunchScreen.storyboard; path = SimpleToastExample/LaunchScreen.storyboard; sourceTree = ""; }; 45 | 89C6BE57DB24E9ADA2F236DE /* Pods-SimpleToastExample-SimpleToastExampleTests.release.xcconfig */ = {isa = PBXFileReference; includeInIndex = 1; lastKnownFileType = text.xcconfig; name = "Pods-SimpleToastExample-SimpleToastExampleTests.release.xcconfig"; path = "Target Support Files/Pods-SimpleToastExample-SimpleToastExampleTests/Pods-SimpleToastExample-SimpleToastExampleTests.release.xcconfig"; sourceTree = ""; }; 46 | ED297162215061F000B7C4FE /* JavaScriptCore.framework */ = {isa = PBXFileReference; lastKnownFileType = wrapper.framework; name = JavaScriptCore.framework; path = System/Library/Frameworks/JavaScriptCore.framework; sourceTree = SDKROOT; }; 47 | /* End PBXFileReference section */ 48 | 49 | /* Begin PBXFrameworksBuildPhase section */ 50 | 00E356EB1AD99517003FC87E /* Frameworks */ = { 51 | isa = PBXFrameworksBuildPhase; 52 | buildActionMask = 2147483647; 53 | files = ( 54 | 7699B88040F8A987B510C191 /* libPods-SimpleToastExample-SimpleToastExampleTests.a in Frameworks */, 55 | ); 56 | runOnlyForDeploymentPostprocessing = 0; 57 | }; 58 | 13B07F8C1A680F5B00A75B9A /* Frameworks */ = { 59 | isa = PBXFrameworksBuildPhase; 60 | buildActionMask = 2147483647; 61 | files = ( 62 | 0C80B921A6F3F58F76C31292 /* libPods-SimpleToastExample.a in Frameworks */, 63 | ); 64 | runOnlyForDeploymentPostprocessing = 0; 65 | }; 66 | /* End PBXFrameworksBuildPhase section */ 67 | 68 | /* Begin PBXGroup section */ 69 | 00E356EF1AD99517003FC87E /* SimpleToastExampleTests */ = { 70 | isa = PBXGroup; 71 | children = ( 72 | 00E356F21AD99517003FC87E /* SimpleToastExampleTests.m */, 73 | 00E356F01AD99517003FC87E /* Supporting Files */, 74 | ); 75 | path = SimpleToastExampleTests; 76 | sourceTree = ""; 77 | }; 78 | 00E356F01AD99517003FC87E /* Supporting Files */ = { 79 | isa = PBXGroup; 80 | children = ( 81 | 00E356F11AD99517003FC87E /* Info.plist */, 82 | ); 83 | name = "Supporting Files"; 84 | sourceTree = ""; 85 | }; 86 | 13B07FAE1A68108700A75B9A /* SimpleToastExample */ = { 87 | isa = PBXGroup; 88 | children = ( 89 | 13B07FAF1A68108700A75B9A /* AppDelegate.h */, 90 | 13B07FB01A68108700A75B9A /* AppDelegate.mm */, 91 | 13B07FB51A68108700A75B9A /* Images.xcassets */, 92 | 13B07FB61A68108700A75B9A /* Info.plist */, 93 | 81AB9BB72411601600AC10FF /* LaunchScreen.storyboard */, 94 | 13B07FB71A68108700A75B9A /* main.m */, 95 | ); 96 | name = SimpleToastExample; 97 | sourceTree = ""; 98 | }; 99 | 2D16E6871FA4F8E400B85C8A /* Frameworks */ = { 100 | isa = PBXGroup; 101 | children = ( 102 | ED297162215061F000B7C4FE /* JavaScriptCore.framework */, 103 | 5DCACB8F33CDC322A6C60F78 /* libPods-SimpleToastExample.a */, 104 | 19F6CBCC0A4E27FBF8BF4A61 /* libPods-SimpleToastExample-SimpleToastExampleTests.a */, 105 | ); 106 | name = Frameworks; 107 | sourceTree = ""; 108 | }; 109 | 832341AE1AAA6A7D00B99B32 /* Libraries */ = { 110 | isa = PBXGroup; 111 | children = ( 112 | ); 113 | name = Libraries; 114 | sourceTree = ""; 115 | }; 116 | 83CBB9F61A601CBA00E9B192 = { 117 | isa = PBXGroup; 118 | children = ( 119 | 13B07FAE1A68108700A75B9A /* SimpleToastExample */, 120 | 832341AE1AAA6A7D00B99B32 /* Libraries */, 121 | 00E356EF1AD99517003FC87E /* SimpleToastExampleTests */, 122 | 83CBBA001A601CBA00E9B192 /* Products */, 123 | 2D16E6871FA4F8E400B85C8A /* Frameworks */, 124 | BBD78D7AC51CEA395F1C20DB /* Pods */, 125 | ); 126 | indentWidth = 2; 127 | sourceTree = ""; 128 | tabWidth = 2; 129 | usesTabs = 0; 130 | }; 131 | 83CBBA001A601CBA00E9B192 /* Products */ = { 132 | isa = PBXGroup; 133 | children = ( 134 | 13B07F961A680F5B00A75B9A /* SimpleToastExample.app */, 135 | 00E356EE1AD99517003FC87E /* SimpleToastExampleTests.xctest */, 136 | ); 137 | name = Products; 138 | sourceTree = ""; 139 | }; 140 | BBD78D7AC51CEA395F1C20DB /* Pods */ = { 141 | isa = PBXGroup; 142 | children = ( 143 | 3B4392A12AC88292D35C810B /* Pods-SimpleToastExample.debug.xcconfig */, 144 | 5709B34CF0A7D63546082F79 /* Pods-SimpleToastExample.release.xcconfig */, 145 | 5B7EB9410499542E8C5724F5 /* Pods-SimpleToastExample-SimpleToastExampleTests.debug.xcconfig */, 146 | 89C6BE57DB24E9ADA2F236DE /* Pods-SimpleToastExample-SimpleToastExampleTests.release.xcconfig */, 147 | ); 148 | path = Pods; 149 | sourceTree = ""; 150 | }; 151 | /* End PBXGroup section */ 152 | 153 | /* Begin PBXNativeTarget section */ 154 | 00E356ED1AD99517003FC87E /* SimpleToastExampleTests */ = { 155 | isa = PBXNativeTarget; 156 | buildConfigurationList = 00E357021AD99517003FC87E /* Build configuration list for PBXNativeTarget "SimpleToastExampleTests" */; 157 | buildPhases = ( 158 | A55EABD7B0C7F3A422A6CC61 /* [CP] Check Pods Manifest.lock */, 159 | 00E356EA1AD99517003FC87E /* Sources */, 160 | 00E356EB1AD99517003FC87E /* Frameworks */, 161 | 00E356EC1AD99517003FC87E /* Resources */, 162 | C59DA0FBD6956966B86A3779 /* [CP] Embed Pods Frameworks */, 163 | F6A41C54EA430FDDC6A6ED99 /* [CP] Copy Pods Resources */, 164 | ); 165 | buildRules = ( 166 | ); 167 | dependencies = ( 168 | 00E356F51AD99517003FC87E /* PBXTargetDependency */, 169 | ); 170 | name = SimpleToastExampleTests; 171 | productName = SimpleToastExampleTests; 172 | productReference = 00E356EE1AD99517003FC87E /* SimpleToastExampleTests.xctest */; 173 | productType = "com.apple.product-type.bundle.unit-test"; 174 | }; 175 | 13B07F861A680F5B00A75B9A /* SimpleToastExample */ = { 176 | isa = PBXNativeTarget; 177 | buildConfigurationList = 13B07F931A680F5B00A75B9A /* Build configuration list for PBXNativeTarget "SimpleToastExample" */; 178 | buildPhases = ( 179 | C38B50BA6285516D6DCD4F65 /* [CP] Check Pods Manifest.lock */, 180 | FD10A7F022414F080027D42C /* Start Packager */, 181 | 13B07F871A680F5B00A75B9A /* Sources */, 182 | 13B07F8C1A680F5B00A75B9A /* Frameworks */, 183 | 13B07F8E1A680F5B00A75B9A /* Resources */, 184 | 00DD1BFF1BD5951E006B06BC /* Bundle React Native code and images */, 185 | 00EEFC60759A1932668264C0 /* [CP] Embed Pods Frameworks */, 186 | E235C05ADACE081382539298 /* [CP] Copy Pods Resources */, 187 | ); 188 | buildRules = ( 189 | ); 190 | dependencies = ( 191 | ); 192 | name = SimpleToastExample; 193 | productName = SimpleToastExample; 194 | productReference = 13B07F961A680F5B00A75B9A /* SimpleToastExample.app */; 195 | productType = "com.apple.product-type.application"; 196 | }; 197 | /* End PBXNativeTarget section */ 198 | 199 | /* Begin PBXProject section */ 200 | 83CBB9F71A601CBA00E9B192 /* Project object */ = { 201 | isa = PBXProject; 202 | attributes = { 203 | LastUpgradeCheck = 1210; 204 | TargetAttributes = { 205 | 00E356ED1AD99517003FC87E = { 206 | CreatedOnToolsVersion = 6.2; 207 | TestTargetID = 13B07F861A680F5B00A75B9A; 208 | }; 209 | 13B07F861A680F5B00A75B9A = { 210 | LastSwiftMigration = 1120; 211 | }; 212 | }; 213 | }; 214 | buildConfigurationList = 83CBB9FA1A601CBA00E9B192 /* Build configuration list for PBXProject "SimpleToastExample" */; 215 | compatibilityVersion = "Xcode 12.0"; 216 | developmentRegion = en; 217 | hasScannedForEncodings = 0; 218 | knownRegions = ( 219 | en, 220 | Base, 221 | ); 222 | mainGroup = 83CBB9F61A601CBA00E9B192; 223 | productRefGroup = 83CBBA001A601CBA00E9B192 /* Products */; 224 | projectDirPath = ""; 225 | projectRoot = ""; 226 | targets = ( 227 | 13B07F861A680F5B00A75B9A /* SimpleToastExample */, 228 | 00E356ED1AD99517003FC87E /* SimpleToastExampleTests */, 229 | ); 230 | }; 231 | /* End PBXProject section */ 232 | 233 | /* Begin PBXResourcesBuildPhase section */ 234 | 00E356EC1AD99517003FC87E /* Resources */ = { 235 | isa = PBXResourcesBuildPhase; 236 | buildActionMask = 2147483647; 237 | files = ( 238 | ); 239 | runOnlyForDeploymentPostprocessing = 0; 240 | }; 241 | 13B07F8E1A680F5B00A75B9A /* Resources */ = { 242 | isa = PBXResourcesBuildPhase; 243 | buildActionMask = 2147483647; 244 | files = ( 245 | 81AB9BB82411601600AC10FF /* LaunchScreen.storyboard in Resources */, 246 | 13B07FBF1A68108700A75B9A /* Images.xcassets in Resources */, 247 | ); 248 | runOnlyForDeploymentPostprocessing = 0; 249 | }; 250 | /* End PBXResourcesBuildPhase section */ 251 | 252 | /* Begin PBXShellScriptBuildPhase section */ 253 | 00DD1BFF1BD5951E006B06BC /* Bundle React Native code and images */ = { 254 | isa = PBXShellScriptBuildPhase; 255 | buildActionMask = 2147483647; 256 | files = ( 257 | ); 258 | inputPaths = ( 259 | "$(SRCROOT)/.xcode.env.local", 260 | "$(SRCROOT)/.xcode.env", 261 | ); 262 | name = "Bundle React Native code and images"; 263 | outputPaths = ( 264 | ); 265 | runOnlyForDeploymentPostprocessing = 0; 266 | shellPath = /bin/sh; 267 | shellScript = "set -e\n\nWITH_ENVIRONMENT=\"../node_modules/react-native/scripts/xcode/with-environment.sh\"\nREACT_NATIVE_XCODE=\"../node_modules/react-native/scripts/react-native-xcode.sh\"\n\n/bin/sh -c \"$WITH_ENVIRONMENT $REACT_NATIVE_XCODE\"\n"; 268 | }; 269 | 00EEFC60759A1932668264C0 /* [CP] Embed Pods Frameworks */ = { 270 | isa = PBXShellScriptBuildPhase; 271 | buildActionMask = 2147483647; 272 | files = ( 273 | ); 274 | inputFileListPaths = ( 275 | "${PODS_ROOT}/Target Support Files/Pods-SimpleToastExample/Pods-SimpleToastExample-frameworks-${CONFIGURATION}-input-files.xcfilelist", 276 | ); 277 | name = "[CP] Embed Pods Frameworks"; 278 | outputFileListPaths = ( 279 | "${PODS_ROOT}/Target Support Files/Pods-SimpleToastExample/Pods-SimpleToastExample-frameworks-${CONFIGURATION}-output-files.xcfilelist", 280 | ); 281 | runOnlyForDeploymentPostprocessing = 0; 282 | shellPath = /bin/sh; 283 | shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-SimpleToastExample/Pods-SimpleToastExample-frameworks.sh\"\n"; 284 | showEnvVarsInLog = 0; 285 | }; 286 | A55EABD7B0C7F3A422A6CC61 /* [CP] Check Pods Manifest.lock */ = { 287 | isa = PBXShellScriptBuildPhase; 288 | buildActionMask = 2147483647; 289 | files = ( 290 | ); 291 | inputFileListPaths = ( 292 | ); 293 | inputPaths = ( 294 | "${PODS_PODFILE_DIR_PATH}/Podfile.lock", 295 | "${PODS_ROOT}/Manifest.lock", 296 | ); 297 | name = "[CP] Check Pods Manifest.lock"; 298 | outputFileListPaths = ( 299 | ); 300 | outputPaths = ( 301 | "$(DERIVED_FILE_DIR)/Pods-SimpleToastExample-SimpleToastExampleTests-checkManifestLockResult.txt", 302 | ); 303 | runOnlyForDeploymentPostprocessing = 0; 304 | shellPath = /bin/sh; 305 | shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; 306 | showEnvVarsInLog = 0; 307 | }; 308 | C38B50BA6285516D6DCD4F65 /* [CP] Check Pods Manifest.lock */ = { 309 | isa = PBXShellScriptBuildPhase; 310 | buildActionMask = 2147483647; 311 | files = ( 312 | ); 313 | inputFileListPaths = ( 314 | ); 315 | inputPaths = ( 316 | "${PODS_PODFILE_DIR_PATH}/Podfile.lock", 317 | "${PODS_ROOT}/Manifest.lock", 318 | ); 319 | name = "[CP] Check Pods Manifest.lock"; 320 | outputFileListPaths = ( 321 | ); 322 | outputPaths = ( 323 | "$(DERIVED_FILE_DIR)/Pods-SimpleToastExample-checkManifestLockResult.txt", 324 | ); 325 | runOnlyForDeploymentPostprocessing = 0; 326 | shellPath = /bin/sh; 327 | shellScript = "diff \"${PODS_PODFILE_DIR_PATH}/Podfile.lock\" \"${PODS_ROOT}/Manifest.lock\" > /dev/null\nif [ $? != 0 ] ; then\n # print error to STDERR\n echo \"error: The sandbox is not in sync with the Podfile.lock. Run 'pod install' or update your CocoaPods installation.\" >&2\n exit 1\nfi\n# This output is used by Xcode 'outputs' to avoid re-running this script phase.\necho \"SUCCESS\" > \"${SCRIPT_OUTPUT_FILE_0}\"\n"; 328 | showEnvVarsInLog = 0; 329 | }; 330 | C59DA0FBD6956966B86A3779 /* [CP] Embed Pods Frameworks */ = { 331 | isa = PBXShellScriptBuildPhase; 332 | buildActionMask = 2147483647; 333 | files = ( 334 | ); 335 | inputFileListPaths = ( 336 | "${PODS_ROOT}/Target Support Files/Pods-SimpleToastExample-SimpleToastExampleTests/Pods-SimpleToastExample-SimpleToastExampleTests-frameworks-${CONFIGURATION}-input-files.xcfilelist", 337 | ); 338 | name = "[CP] Embed Pods Frameworks"; 339 | outputFileListPaths = ( 340 | "${PODS_ROOT}/Target Support Files/Pods-SimpleToastExample-SimpleToastExampleTests/Pods-SimpleToastExample-SimpleToastExampleTests-frameworks-${CONFIGURATION}-output-files.xcfilelist", 341 | ); 342 | runOnlyForDeploymentPostprocessing = 0; 343 | shellPath = /bin/sh; 344 | shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-SimpleToastExample-SimpleToastExampleTests/Pods-SimpleToastExample-SimpleToastExampleTests-frameworks.sh\"\n"; 345 | showEnvVarsInLog = 0; 346 | }; 347 | E235C05ADACE081382539298 /* [CP] Copy Pods Resources */ = { 348 | isa = PBXShellScriptBuildPhase; 349 | buildActionMask = 2147483647; 350 | files = ( 351 | ); 352 | inputFileListPaths = ( 353 | "${PODS_ROOT}/Target Support Files/Pods-SimpleToastExample/Pods-SimpleToastExample-resources-${CONFIGURATION}-input-files.xcfilelist", 354 | ); 355 | name = "[CP] Copy Pods Resources"; 356 | outputFileListPaths = ( 357 | "${PODS_ROOT}/Target Support Files/Pods-SimpleToastExample/Pods-SimpleToastExample-resources-${CONFIGURATION}-output-files.xcfilelist", 358 | ); 359 | runOnlyForDeploymentPostprocessing = 0; 360 | shellPath = /bin/sh; 361 | shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-SimpleToastExample/Pods-SimpleToastExample-resources.sh\"\n"; 362 | showEnvVarsInLog = 0; 363 | }; 364 | F6A41C54EA430FDDC6A6ED99 /* [CP] Copy Pods Resources */ = { 365 | isa = PBXShellScriptBuildPhase; 366 | buildActionMask = 2147483647; 367 | files = ( 368 | ); 369 | inputFileListPaths = ( 370 | "${PODS_ROOT}/Target Support Files/Pods-SimpleToastExample-SimpleToastExampleTests/Pods-SimpleToastExample-SimpleToastExampleTests-resources-${CONFIGURATION}-input-files.xcfilelist", 371 | ); 372 | name = "[CP] Copy Pods Resources"; 373 | outputFileListPaths = ( 374 | "${PODS_ROOT}/Target Support Files/Pods-SimpleToastExample-SimpleToastExampleTests/Pods-SimpleToastExample-SimpleToastExampleTests-resources-${CONFIGURATION}-output-files.xcfilelist", 375 | ); 376 | runOnlyForDeploymentPostprocessing = 0; 377 | shellPath = /bin/sh; 378 | shellScript = "\"${PODS_ROOT}/Target Support Files/Pods-SimpleToastExample-SimpleToastExampleTests/Pods-SimpleToastExample-SimpleToastExampleTests-resources.sh\"\n"; 379 | showEnvVarsInLog = 0; 380 | }; 381 | FD10A7F022414F080027D42C /* Start Packager */ = { 382 | isa = PBXShellScriptBuildPhase; 383 | buildActionMask = 2147483647; 384 | files = ( 385 | ); 386 | inputFileListPaths = ( 387 | ); 388 | inputPaths = ( 389 | ); 390 | name = "Start Packager"; 391 | outputFileListPaths = ( 392 | ); 393 | outputPaths = ( 394 | ); 395 | runOnlyForDeploymentPostprocessing = 0; 396 | shellPath = /bin/sh; 397 | shellScript = "export RCT_METRO_PORT=\"${RCT_METRO_PORT:=8081}\"\necho \"export RCT_METRO_PORT=${RCT_METRO_PORT}\" > \"${SRCROOT}/../node_modules/react-native/scripts/.packager.env\"\nif [ -z \"${RCT_NO_LAUNCH_PACKAGER+xxx}\" ] ; then\n if nc -w 5 -z localhost ${RCT_METRO_PORT} ; then\n if ! curl -s \"http://localhost:${RCT_METRO_PORT}/status\" | grep -q \"packager-status:running\" ; then\n echo \"Port ${RCT_METRO_PORT} already in use, packager is either not running or not running correctly\"\n exit 2\n fi\n else\n open \"$SRCROOT/../node_modules/react-native/scripts/launchPackager.command\" || echo \"Can't start packager automatically\"\n fi\nfi\n"; 398 | showEnvVarsInLog = 0; 399 | }; 400 | /* End PBXShellScriptBuildPhase section */ 401 | 402 | /* Begin PBXSourcesBuildPhase section */ 403 | 00E356EA1AD99517003FC87E /* Sources */ = { 404 | isa = PBXSourcesBuildPhase; 405 | buildActionMask = 2147483647; 406 | files = ( 407 | 00E356F31AD99517003FC87E /* SimpleToastExampleTests.m in Sources */, 408 | ); 409 | runOnlyForDeploymentPostprocessing = 0; 410 | }; 411 | 13B07F871A680F5B00A75B9A /* Sources */ = { 412 | isa = PBXSourcesBuildPhase; 413 | buildActionMask = 2147483647; 414 | files = ( 415 | 13B07FBC1A68108700A75B9A /* AppDelegate.mm in Sources */, 416 | 13B07FC11A68108700A75B9A /* main.m in Sources */, 417 | ); 418 | runOnlyForDeploymentPostprocessing = 0; 419 | }; 420 | /* End PBXSourcesBuildPhase section */ 421 | 422 | /* Begin PBXTargetDependency section */ 423 | 00E356F51AD99517003FC87E /* PBXTargetDependency */ = { 424 | isa = PBXTargetDependency; 425 | target = 13B07F861A680F5B00A75B9A /* SimpleToastExample */; 426 | targetProxy = 00E356F41AD99517003FC87E /* PBXContainerItemProxy */; 427 | }; 428 | /* End PBXTargetDependency section */ 429 | 430 | /* Begin XCBuildConfiguration section */ 431 | 00E356F61AD99517003FC87E /* Debug */ = { 432 | isa = XCBuildConfiguration; 433 | baseConfigurationReference = 5B7EB9410499542E8C5724F5 /* Pods-SimpleToastExample-SimpleToastExampleTests.debug.xcconfig */; 434 | buildSettings = { 435 | BUNDLE_LOADER = "$(TEST_HOST)"; 436 | GCC_PREPROCESSOR_DEFINITIONS = ( 437 | "DEBUG=1", 438 | "$(inherited)", 439 | ); 440 | INFOPLIST_FILE = SimpleToastExampleTests/Info.plist; 441 | IPHONEOS_DEPLOYMENT_TARGET = 12.4; 442 | LD_RUNPATH_SEARCH_PATHS = ( 443 | "$(inherited)", 444 | "@executable_path/Frameworks", 445 | "@loader_path/Frameworks", 446 | ); 447 | OTHER_LDFLAGS = ( 448 | "-ObjC", 449 | "-lc++", 450 | "$(inherited)", 451 | ); 452 | PRODUCT_BUNDLE_IDENTIFIER = "org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)"; 453 | PRODUCT_NAME = "$(TARGET_NAME)"; 454 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/SimpleToastExample.app/SimpleToastExample"; 455 | }; 456 | name = Debug; 457 | }; 458 | 00E356F71AD99517003FC87E /* Release */ = { 459 | isa = XCBuildConfiguration; 460 | baseConfigurationReference = 89C6BE57DB24E9ADA2F236DE /* Pods-SimpleToastExample-SimpleToastExampleTests.release.xcconfig */; 461 | buildSettings = { 462 | BUNDLE_LOADER = "$(TEST_HOST)"; 463 | COPY_PHASE_STRIP = NO; 464 | INFOPLIST_FILE = SimpleToastExampleTests/Info.plist; 465 | IPHONEOS_DEPLOYMENT_TARGET = 12.4; 466 | LD_RUNPATH_SEARCH_PATHS = ( 467 | "$(inherited)", 468 | "@executable_path/Frameworks", 469 | "@loader_path/Frameworks", 470 | ); 471 | OTHER_LDFLAGS = ( 472 | "-ObjC", 473 | "-lc++", 474 | "$(inherited)", 475 | ); 476 | PRODUCT_BUNDLE_IDENTIFIER = "org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)"; 477 | PRODUCT_NAME = "$(TARGET_NAME)"; 478 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/SimpleToastExample.app/SimpleToastExample"; 479 | }; 480 | name = Release; 481 | }; 482 | 13B07F941A680F5B00A75B9A /* Debug */ = { 483 | isa = XCBuildConfiguration; 484 | baseConfigurationReference = 3B4392A12AC88292D35C810B /* Pods-SimpleToastExample.debug.xcconfig */; 485 | buildSettings = { 486 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 487 | CLANG_ENABLE_MODULES = YES; 488 | CURRENT_PROJECT_VERSION = 1; 489 | ENABLE_BITCODE = NO; 490 | INFOPLIST_FILE = SimpleToastExample/Info.plist; 491 | LD_RUNPATH_SEARCH_PATHS = ( 492 | "$(inherited)", 493 | "@executable_path/Frameworks", 494 | ); 495 | MARKETING_VERSION = 1.0; 496 | OTHER_LDFLAGS = ( 497 | "$(inherited)", 498 | "-ObjC", 499 | "-lc++", 500 | ); 501 | PRODUCT_BUNDLE_IDENTIFIER = "org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)"; 502 | PRODUCT_NAME = SimpleToastExample; 503 | SWIFT_OPTIMIZATION_LEVEL = "-Onone"; 504 | SWIFT_VERSION = 5.0; 505 | VERSIONING_SYSTEM = "apple-generic"; 506 | }; 507 | name = Debug; 508 | }; 509 | 13B07F951A680F5B00A75B9A /* Release */ = { 510 | isa = XCBuildConfiguration; 511 | baseConfigurationReference = 5709B34CF0A7D63546082F79 /* Pods-SimpleToastExample.release.xcconfig */; 512 | buildSettings = { 513 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; 514 | CLANG_ENABLE_MODULES = YES; 515 | CURRENT_PROJECT_VERSION = 1; 516 | INFOPLIST_FILE = SimpleToastExample/Info.plist; 517 | LD_RUNPATH_SEARCH_PATHS = ( 518 | "$(inherited)", 519 | "@executable_path/Frameworks", 520 | ); 521 | MARKETING_VERSION = 1.0; 522 | OTHER_LDFLAGS = ( 523 | "$(inherited)", 524 | "-ObjC", 525 | "-lc++", 526 | ); 527 | PRODUCT_BUNDLE_IDENTIFIER = "org.reactjs.native.example.$(PRODUCT_NAME:rfc1034identifier)"; 528 | PRODUCT_NAME = SimpleToastExample; 529 | SWIFT_VERSION = 5.0; 530 | VERSIONING_SYSTEM = "apple-generic"; 531 | }; 532 | name = Release; 533 | }; 534 | 83CBBA201A601CBA00E9B192 /* Debug */ = { 535 | isa = XCBuildConfiguration; 536 | buildSettings = { 537 | ALWAYS_SEARCH_USER_PATHS = NO; 538 | CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; 539 | CLANG_CXX_LANGUAGE_STANDARD = "c++17"; 540 | CLANG_CXX_LIBRARY = "libc++"; 541 | CLANG_ENABLE_MODULES = YES; 542 | CLANG_ENABLE_OBJC_ARC = YES; 543 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 544 | CLANG_WARN_BOOL_CONVERSION = YES; 545 | CLANG_WARN_COMMA = YES; 546 | CLANG_WARN_CONSTANT_CONVERSION = YES; 547 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 548 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 549 | CLANG_WARN_EMPTY_BODY = YES; 550 | CLANG_WARN_ENUM_CONVERSION = YES; 551 | CLANG_WARN_INFINITE_RECURSION = YES; 552 | CLANG_WARN_INT_CONVERSION = YES; 553 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 554 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 555 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 556 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 557 | CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; 558 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 559 | CLANG_WARN_STRICT_PROTOTYPES = YES; 560 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 561 | CLANG_WARN_UNREACHABLE_CODE = YES; 562 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 563 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 564 | COPY_PHASE_STRIP = NO; 565 | ENABLE_STRICT_OBJC_MSGSEND = YES; 566 | ENABLE_TESTABILITY = YES; 567 | "EXCLUDED_ARCHS[sdk=iphonesimulator*]" = i386; 568 | GCC_C_LANGUAGE_STANDARD = gnu99; 569 | GCC_DYNAMIC_NO_PIC = NO; 570 | GCC_NO_COMMON_BLOCKS = YES; 571 | GCC_OPTIMIZATION_LEVEL = 0; 572 | GCC_PREPROCESSOR_DEFINITIONS = ( 573 | "DEBUG=1", 574 | "$(inherited)", 575 | ); 576 | GCC_SYMBOLS_PRIVATE_EXTERN = NO; 577 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 578 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 579 | GCC_WARN_UNDECLARED_SELECTOR = YES; 580 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 581 | GCC_WARN_UNUSED_FUNCTION = YES; 582 | GCC_WARN_UNUSED_VARIABLE = YES; 583 | IPHONEOS_DEPLOYMENT_TARGET = 12.4; 584 | LD_RUNPATH_SEARCH_PATHS = ( 585 | /usr/lib/swift, 586 | "$(inherited)", 587 | ); 588 | LIBRARY_SEARCH_PATHS = ( 589 | "\"$(SDKROOT)/usr/lib/swift\"", 590 | "\"$(TOOLCHAIN_DIR)/usr/lib/swift/$(PLATFORM_NAME)\"", 591 | "\"$(inherited)\"", 592 | ); 593 | MTL_ENABLE_DEBUG_INFO = YES; 594 | ONLY_ACTIVE_ARCH = YES; 595 | OTHER_CPLUSPLUSFLAGS = ( 596 | "$(OTHER_CFLAGS)", 597 | "-DFOLLY_NO_CONFIG", 598 | "-DFOLLY_MOBILE=1", 599 | "-DFOLLY_USE_LIBCPP=1", 600 | ); 601 | REACT_NATIVE_PATH = "${PODS_ROOT}/../../node_modules/react-native"; 602 | SDKROOT = iphoneos; 603 | }; 604 | name = Debug; 605 | }; 606 | 83CBBA211A601CBA00E9B192 /* Release */ = { 607 | isa = XCBuildConfiguration; 608 | buildSettings = { 609 | ALWAYS_SEARCH_USER_PATHS = NO; 610 | CLANG_ANALYZER_LOCALIZABILITY_NONLOCALIZED = YES; 611 | CLANG_CXX_LANGUAGE_STANDARD = "c++17"; 612 | CLANG_CXX_LIBRARY = "libc++"; 613 | CLANG_ENABLE_MODULES = YES; 614 | CLANG_ENABLE_OBJC_ARC = YES; 615 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; 616 | CLANG_WARN_BOOL_CONVERSION = YES; 617 | CLANG_WARN_COMMA = YES; 618 | CLANG_WARN_CONSTANT_CONVERSION = YES; 619 | CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; 620 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; 621 | CLANG_WARN_EMPTY_BODY = YES; 622 | CLANG_WARN_ENUM_CONVERSION = YES; 623 | CLANG_WARN_INFINITE_RECURSION = YES; 624 | CLANG_WARN_INT_CONVERSION = YES; 625 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; 626 | CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; 627 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; 628 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; 629 | CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; 630 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; 631 | CLANG_WARN_STRICT_PROTOTYPES = YES; 632 | CLANG_WARN_SUSPICIOUS_MOVE = YES; 633 | CLANG_WARN_UNREACHABLE_CODE = YES; 634 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; 635 | "CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer"; 636 | COPY_PHASE_STRIP = YES; 637 | ENABLE_NS_ASSERTIONS = NO; 638 | ENABLE_STRICT_OBJC_MSGSEND = YES; 639 | "EXCLUDED_ARCHS[sdk=iphonesimulator*]" = i386; 640 | GCC_C_LANGUAGE_STANDARD = gnu99; 641 | GCC_NO_COMMON_BLOCKS = YES; 642 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES; 643 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; 644 | GCC_WARN_UNDECLARED_SELECTOR = YES; 645 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; 646 | GCC_WARN_UNUSED_FUNCTION = YES; 647 | GCC_WARN_UNUSED_VARIABLE = YES; 648 | IPHONEOS_DEPLOYMENT_TARGET = 12.4; 649 | LD_RUNPATH_SEARCH_PATHS = ( 650 | /usr/lib/swift, 651 | "$(inherited)", 652 | ); 653 | LIBRARY_SEARCH_PATHS = ( 654 | "\"$(SDKROOT)/usr/lib/swift\"", 655 | "\"$(TOOLCHAIN_DIR)/usr/lib/swift/$(PLATFORM_NAME)\"", 656 | "\"$(inherited)\"", 657 | ); 658 | MTL_ENABLE_DEBUG_INFO = NO; 659 | OTHER_CPLUSPLUSFLAGS = ( 660 | "$(OTHER_CFLAGS)", 661 | "-DFOLLY_NO_CONFIG", 662 | "-DFOLLY_MOBILE=1", 663 | "-DFOLLY_USE_LIBCPP=1", 664 | ); 665 | REACT_NATIVE_PATH = "${PODS_ROOT}/../../node_modules/react-native"; 666 | SDKROOT = iphoneos; 667 | VALIDATE_PRODUCT = YES; 668 | }; 669 | name = Release; 670 | }; 671 | /* End XCBuildConfiguration section */ 672 | 673 | /* Begin XCConfigurationList section */ 674 | 00E357021AD99517003FC87E /* Build configuration list for PBXNativeTarget "SimpleToastExampleTests" */ = { 675 | isa = XCConfigurationList; 676 | buildConfigurations = ( 677 | 00E356F61AD99517003FC87E /* Debug */, 678 | 00E356F71AD99517003FC87E /* Release */, 679 | ); 680 | defaultConfigurationIsVisible = 0; 681 | defaultConfigurationName = Release; 682 | }; 683 | 13B07F931A680F5B00A75B9A /* Build configuration list for PBXNativeTarget "SimpleToastExample" */ = { 684 | isa = XCConfigurationList; 685 | buildConfigurations = ( 686 | 13B07F941A680F5B00A75B9A /* Debug */, 687 | 13B07F951A680F5B00A75B9A /* Release */, 688 | ); 689 | defaultConfigurationIsVisible = 0; 690 | defaultConfigurationName = Release; 691 | }; 692 | 83CBB9FA1A601CBA00E9B192 /* Build configuration list for PBXProject "SimpleToastExample" */ = { 693 | isa = XCConfigurationList; 694 | buildConfigurations = ( 695 | 83CBBA201A601CBA00E9B192 /* Debug */, 696 | 83CBBA211A601CBA00E9B192 /* Release */, 697 | ); 698 | defaultConfigurationIsVisible = 0; 699 | defaultConfigurationName = Release; 700 | }; 701 | /* End XCConfigurationList section */ 702 | }; 703 | rootObject = 83CBB9F71A601CBA00E9B192 /* Project object */; 704 | } 705 | -------------------------------------------------------------------------------- /example/ios/SimpleToastExample.xcodeproj/xcshareddata/xcschemes/SimpleToastExample.xcscheme: -------------------------------------------------------------------------------- 1 | 2 | 5 | 8 | 9 | 15 | 21 | 22 | 23 | 24 | 25 | 30 | 31 | 33 | 39 | 40 | 41 | 42 | 43 | 53 | 55 | 61 | 62 | 63 | 64 | 70 | 72 | 78 | 79 | 80 | 81 | 83 | 84 | 87 | 88 | 89 | -------------------------------------------------------------------------------- /example/ios/SimpleToastExample.xcworkspace/contents.xcworkspacedata: -------------------------------------------------------------------------------- 1 | 2 | 4 | 6 | 7 | 9 | 10 | 11 | -------------------------------------------------------------------------------- /example/ios/SimpleToastExample.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | IDEDidComputeMac32BitWarning 6 | 7 | 8 | 9 | -------------------------------------------------------------------------------- /example/ios/SimpleToastExample/AppDelegate.h: -------------------------------------------------------------------------------- 1 | #import 2 | #import 3 | 4 | @interface AppDelegate : RCTAppDelegate 5 | 6 | @end 7 | -------------------------------------------------------------------------------- /example/ios/SimpleToastExample/AppDelegate.mm: -------------------------------------------------------------------------------- 1 | #import "AppDelegate.h" 2 | 3 | #import 4 | 5 | @implementation AppDelegate 6 | 7 | - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions 8 | { 9 | self.moduleName = @"SimpleToastExample"; 10 | return [super application:application didFinishLaunchingWithOptions:launchOptions]; 11 | } 12 | 13 | - (NSURL *)sourceURLForBridge:(RCTBridge *)bridge 14 | { 15 | #if DEBUG 16 | return [[RCTBundleURLProvider sharedSettings] jsBundleURLForBundleRoot:@"index"]; 17 | #else 18 | return [[NSBundle mainBundle] URLForResource:@"main" withExtension:@"jsbundle"]; 19 | #endif 20 | } 21 | 22 | /// This method controls whether the `concurrentRoot`feature of React18 is turned on or off. 23 | /// 24 | /// @see: https://reactjs.org/blog/2022/03/29/react-v18.html 25 | /// @note: This requires to be rendering on Fabric (i.e. on the New Architecture). 26 | /// @return: `true` if the `concurrentRoot` feature is enabled. Otherwise, it returns `false`. 27 | - (BOOL)concurrentRootEnabled 28 | { 29 | return true; 30 | } 31 | 32 | @end 33 | -------------------------------------------------------------------------------- /example/ios/SimpleToastExample/Images.xcassets/AppIcon.appiconset/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "images" : [ 3 | { 4 | "idiom" : "iphone", 5 | "scale" : "2x", 6 | "size" : "20x20" 7 | }, 8 | { 9 | "idiom" : "iphone", 10 | "scale" : "3x", 11 | "size" : "20x20" 12 | }, 13 | { 14 | "idiom" : "iphone", 15 | "scale" : "2x", 16 | "size" : "29x29" 17 | }, 18 | { 19 | "idiom" : "iphone", 20 | "scale" : "3x", 21 | "size" : "29x29" 22 | }, 23 | { 24 | "idiom" : "iphone", 25 | "scale" : "2x", 26 | "size" : "40x40" 27 | }, 28 | { 29 | "idiom" : "iphone", 30 | "scale" : "3x", 31 | "size" : "40x40" 32 | }, 33 | { 34 | "idiom" : "iphone", 35 | "scale" : "2x", 36 | "size" : "60x60" 37 | }, 38 | { 39 | "idiom" : "iphone", 40 | "scale" : "3x", 41 | "size" : "60x60" 42 | }, 43 | { 44 | "idiom" : "ios-marketing", 45 | "scale" : "1x", 46 | "size" : "1024x1024" 47 | } 48 | ], 49 | "info" : { 50 | "author" : "xcode", 51 | "version" : 1 52 | } 53 | } 54 | -------------------------------------------------------------------------------- /example/ios/SimpleToastExample/Images.xcassets/Contents.json: -------------------------------------------------------------------------------- 1 | { 2 | "info" : { 3 | "version" : 1, 4 | "author" : "xcode" 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /example/ios/SimpleToastExample/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleDisplayName 8 | SimpleToastExample 9 | CFBundleExecutable 10 | $(EXECUTABLE_NAME) 11 | CFBundleIdentifier 12 | $(PRODUCT_BUNDLE_IDENTIFIER) 13 | CFBundleInfoDictionaryVersion 14 | 6.0 15 | CFBundleName 16 | $(PRODUCT_NAME) 17 | CFBundlePackageType 18 | APPL 19 | CFBundleShortVersionString 20 | $(MARKETING_VERSION) 21 | CFBundleSignature 22 | ???? 23 | CFBundleVersion 24 | $(CURRENT_PROJECT_VERSION) 25 | LSRequiresIPhoneOS 26 | 27 | NSAppTransportSecurity 28 | 29 | NSExceptionDomains 30 | 31 | localhost 32 | 33 | NSExceptionAllowsInsecureHTTPLoads 34 | 35 | 36 | 37 | 38 | NSLocationWhenInUseUsageDescription 39 | 40 | UILaunchStoryboardName 41 | LaunchScreen 42 | UIRequiredDeviceCapabilities 43 | 44 | armv7 45 | 46 | UISupportedInterfaceOrientations 47 | 48 | UIInterfaceOrientationPortrait 49 | UIInterfaceOrientationLandscapeLeft 50 | UIInterfaceOrientationLandscapeRight 51 | 52 | UIViewControllerBasedStatusBarAppearance 53 | 54 | 55 | 56 | -------------------------------------------------------------------------------- /example/ios/SimpleToastExample/LaunchScreen.storyboard: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 11 | 12 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 24 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | 39 | 40 | 41 | 42 | 43 | 44 | 45 | 46 | 47 | 48 | -------------------------------------------------------------------------------- /example/ios/SimpleToastExample/main.m: -------------------------------------------------------------------------------- 1 | #import 2 | 3 | #import "AppDelegate.h" 4 | 5 | int main(int argc, char *argv[]) 6 | { 7 | @autoreleasepool { 8 | return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class])); 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /example/ios/SimpleToastExampleTests/Info.plist: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | CFBundleDevelopmentRegion 6 | en 7 | CFBundleExecutable 8 | $(EXECUTABLE_NAME) 9 | CFBundleIdentifier 10 | $(PRODUCT_BUNDLE_IDENTIFIER) 11 | CFBundleInfoDictionaryVersion 12 | 6.0 13 | CFBundleName 14 | $(PRODUCT_NAME) 15 | CFBundlePackageType 16 | BNDL 17 | CFBundleShortVersionString 18 | 1.0 19 | CFBundleSignature 20 | ???? 21 | CFBundleVersion 22 | 1 23 | 24 | 25 | -------------------------------------------------------------------------------- /example/ios/SimpleToastExampleTests/SimpleToastExampleTests.m: -------------------------------------------------------------------------------- 1 | #import 2 | #import 3 | 4 | #import 5 | #import 6 | 7 | #define TIMEOUT_SECONDS 600 8 | #define TEXT_TO_LOOK_FOR @"Welcome to React" 9 | 10 | @interface SimpleToastExampleTests : XCTestCase 11 | 12 | @end 13 | 14 | @implementation SimpleToastExampleTests 15 | 16 | - (BOOL)findSubviewInView:(UIView *)view matching:(BOOL (^)(UIView *view))test 17 | { 18 | if (test(view)) { 19 | return YES; 20 | } 21 | for (UIView *subview in [view subviews]) { 22 | if ([self findSubviewInView:subview matching:test]) { 23 | return YES; 24 | } 25 | } 26 | return NO; 27 | } 28 | 29 | - (void)testRendersWelcomeScreen 30 | { 31 | UIViewController *vc = [[[RCTSharedApplication() delegate] window] rootViewController]; 32 | NSDate *date = [NSDate dateWithTimeIntervalSinceNow:TIMEOUT_SECONDS]; 33 | BOOL foundElement = NO; 34 | 35 | __block NSString *redboxError = nil; 36 | #ifdef DEBUG 37 | RCTSetLogFunction( 38 | ^(RCTLogLevel level, RCTLogSource source, NSString *fileName, NSNumber *lineNumber, NSString *message) { 39 | if (level >= RCTLogLevelError) { 40 | redboxError = message; 41 | } 42 | }); 43 | #endif 44 | 45 | while ([date timeIntervalSinceNow] > 0 && !foundElement && !redboxError) { 46 | [[NSRunLoop mainRunLoop] runMode:NSDefaultRunLoopMode beforeDate:[NSDate dateWithTimeIntervalSinceNow:0.1]]; 47 | [[NSRunLoop mainRunLoop] runMode:NSRunLoopCommonModes beforeDate:[NSDate dateWithTimeIntervalSinceNow:0.1]]; 48 | 49 | foundElement = [self findSubviewInView:vc.view 50 | matching:^BOOL(UIView *view) { 51 | if ([view.accessibilityLabel isEqualToString:TEXT_TO_LOOK_FOR]) { 52 | return YES; 53 | } 54 | return NO; 55 | }]; 56 | } 57 | 58 | #ifdef DEBUG 59 | RCTSetLogFunction(RCTDefaultLogFunction); 60 | #endif 61 | 62 | XCTAssertNil(redboxError, @"RedBox error: %@", redboxError); 63 | XCTAssertTrue(foundElement, @"Couldn't find element with text '%@' in %d seconds", TEXT_TO_LOOK_FOR, TIMEOUT_SECONDS); 64 | } 65 | 66 | @end 67 | -------------------------------------------------------------------------------- /example/metro.config.js: -------------------------------------------------------------------------------- 1 | const path = require('path'); 2 | const escape = require('escape-string-regexp'); 3 | const exclusionList = require('metro-config/src/defaults/exclusionList'); 4 | const pak = require('../package.json'); 5 | 6 | const root = path.resolve(__dirname, '..'); 7 | 8 | const modules = Object.keys({ 9 | ...pak.peerDependencies, 10 | }); 11 | 12 | module.exports = { 13 | projectRoot: __dirname, 14 | watchFolders: [root], 15 | 16 | // We need to make sure that only one version is loaded for peerDependencies 17 | // So we block them at the root, and alias them to the versions in example's node_modules 18 | resolver: { 19 | blacklistRE: exclusionList( 20 | modules.map( 21 | (m) => 22 | new RegExp(`^${escape(path.join(root, 'node_modules', m))}\\/.*$`), 23 | ), 24 | ), 25 | 26 | extraNodeModules: modules.reduce((acc, name) => { 27 | acc[name] = path.join(__dirname, 'node_modules', name); 28 | return acc; 29 | }, {}), 30 | }, 31 | 32 | transformer: { 33 | getTransformOptions: async () => ({ 34 | transform: { 35 | experimentalImportSupport: false, 36 | inlineRequires: true, 37 | }, 38 | }), 39 | }, 40 | }; 41 | -------------------------------------------------------------------------------- /example/package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "SimpleToastExample", 3 | "version": "0.0.1", 4 | "private": true, 5 | "scripts": { 6 | "android": "react-native run-android", 7 | "ios": "react-native run-ios", 8 | "start": "react-native start", 9 | "pods": "pod-install --quiet" 10 | }, 11 | "dependencies": { 12 | "react": "18.2.0", 13 | "react-native": "0.71.12" 14 | }, 15 | "devDependencies": { 16 | "@babel/core": "^7.12.9", 17 | "@babel/preset-env": "^7.14.0", 18 | "@babel/runtime": "^7.12.5", 19 | "metro-react-native-babel-preset": "0.73.3", 20 | "babel-plugin-module-resolver": "^4.1.0" 21 | } 22 | } 23 | -------------------------------------------------------------------------------- /example/react-native.config.js: -------------------------------------------------------------------------------- 1 | const path = require('path'); 2 | const pak = require('../package.json'); 3 | 4 | module.exports = { 5 | dependencies: { 6 | [pak.name]: { 7 | root: path.join(__dirname, '..'), 8 | }, 9 | }, 10 | }; 11 | -------------------------------------------------------------------------------- /example/src/App.tsx: -------------------------------------------------------------------------------- 1 | import * as React from 'react'; 2 | 3 | import { 4 | StyleSheet, 5 | View, 6 | Button, 7 | Alert, 8 | TextInput, 9 | ScrollView, 10 | Pressable, 11 | Modal, 12 | Text, 13 | } from 'react-native'; 14 | import Toast from 'react-native-simple-toast'; 15 | import { useState } from 'react'; 16 | 17 | export default function App() { 18 | const [modalVisible, setModalVisible] = useState(false); 19 | 20 | return ( 21 | <> 22 | { 27 | Alert.alert('Modal has been closed.'); 28 | setModalVisible(!modalVisible); 29 | }} 30 | > 31 | 32 | 33 | Hello World! 34 | setModalVisible(!modalVisible)} 37 | > 38 | Hide Modal 39 | 40 | 41 | 42 | 43 | 44 | 50 | 51 |