Skip to content

Commit

Permalink
docs: update docs for README and CONTRIBUTING mkdown guides
Browse files Browse the repository at this point in the history
  • Loading branch information
zplata committed Jun 16, 2022
1 parent 028eb74 commit 4a12e23
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 5 deletions.
27 changes: 26 additions & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,31 @@

We want this community to be friendly and respectful to each other. Please follow it in all your interactions with the project.

## Dependency Prereqs

In order to run the example React Native project in this repo, you may need to ensure you have the following dependencies and considerations below installed and taken into account.

### General
Follow dependency installation instructions from the [React Native docs here](https://reactnative.dev/docs/environment-setup#installing-dependencies) to get setup with iOS and Android. Make sure to select the following tabs in the docs:
- Select the **React Native CLI Quickstart** tab
- **Development OS**: `macOS` or other OS you're working with
- **Target OS**: Select either `Android` or `iOS` based on whichever platform you're trying to work with/set up

### iOS

- You may need to run `pod update RiveRuntime` or `pod install` in the `example/iOS` folder to get the runtime updated or installed

### Android
- Follow dependency installation instructions from the [React Native docs here](https://reactnative.dev/docs/environment-setup#installing-dependencies) to get setup with the Android SDK
- Ensure that if you installed a new version of JDK, it is set as the `JAVA_HOME` appropriately in your env system (i.e `.zshrc`). You can also verify the new JDK via `java -version` in the command-line. Set the env variable like so:
```
export JAVA_HOME=/Library/Java/JavaVirtualMachines/adoptopenjdk-11.jdk/Contents/Home`
```

### M1 Considerations

If you're running on an M1, you may need to run terminal-based commands off [Rosetta](https://www.courier.com/blog/tips-and-tricks-to-setup-your-apple-m1-for-development/) as it may not support new M1 architecture.

## Development workflow

To get started with the project, run `yarn` in the root directory to install the required dependencies for each package:
Expand All @@ -14,7 +39,7 @@ yarn
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.

To start the packager:
To start the metro server:

```sh
yarn example start
Expand Down
4 changes: 0 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,10 +46,6 @@ Put `.riv` files inside your project:
- `raw` directory on Android
- `Assets` directory on iOS

### Expo

Since rive-react-native has native bindings to iOS and Android, you need to generate a native project in order to run you app. This can be done with `expo run:android` or `expo run:ios`. See https://docs.expo.dev/workflow/customizing/ for more information.

## Usage

```tsx
Expand Down

0 comments on commit 4a12e23

Please sign in to comment.