|
| 1 | +**How to use this template** |
| 2 | + |
| 3 | +- Put your bindings in `src/ReactNativeSomething` & rename accordingly or use |
| 4 | + `bsconfig.json` `"namespace"` field (more on this below), |
| 5 | +- Update all occurences of |
| 6 | + |
| 7 | + - `@reason-react-native/__template__` |
| 8 | + - `https://github.com/reason-react-native/__template__` |
| 9 | + - `__template__` |
| 10 | + - `@react-native-community/something` |
| 11 | + - `https://github.com/react-native-community/something` |
| 12 | + - `ReactNativeSomething`. If you have more than a file exposed, you should |
| 13 | + consider using BuckleScript custom namespace by adjusting `bsconfig.json` |
| 14 | + and adding a `"namespace": "react-native-something"` (note that it will be |
| 15 | + converted to `ReactNativeSomething`) |
| 16 | + |
| 17 | +- Add your `@react-native-community/something` (adjusted) in `peerDependencies` |
| 18 | + & `devDependencies` section |
| 19 | +- Adjust the changelog (and/or clean it) |
| 20 | +- Remove this part ⬆ & keep everything below ⬇ |
| 21 | + |
| 22 | +--- |
| 23 | + |
| 24 | +# `@reason-react-native/__template__` |
| 25 | + |
| 26 | +[](https://github.com/reason-react-native/__template__/actions) |
| 27 | +[](https://www.npmjs.com/@reason-react-native/__template__) |
| 28 | +[](https://reasonml-community.github.io/reason-react-native/discord/) |
| 29 | + |
| 30 | +[ReasonML](https://reasonml.github.io) / |
| 31 | +[BuckleScript](https://bucklescript.github.io) bindings for |
| 32 | +[`@react-native-community/something`](https://github.com/react-native-community/something). |
| 33 | + |
| 34 | +Exposed as `ReactNativeSomething` module. |
| 35 | + |
| 36 | +`@reason-react-native/__template__` X.y._ means it's compatible with |
| 37 | +`@react-native-community/something` X.y._ |
| 38 | + |
| 39 | +## Installation |
| 40 | + |
| 41 | +When |
| 42 | +[`@react-native-community/something`](https://github.com/react-native-community/something) |
| 43 | +is properly installed & configured by following their installation instructions, |
| 44 | +you can install the bindings: |
| 45 | + |
| 46 | +```console |
| 47 | +npm install @reason-react-native/__template__ |
| 48 | +# or |
| 49 | +yarn add @reason-react-native/__template__ |
| 50 | +``` |
| 51 | + |
| 52 | +`@reason-react-native/__template__` should be added to `bs-dependencies` in your |
| 53 | +`bsconfig.json`. Something like |
| 54 | + |
| 55 | +```diff |
| 56 | +{ |
| 57 | + //... |
| 58 | + "bs-dependencies": [ |
| 59 | + "reason-react", |
| 60 | + "reason-react-native", |
| 61 | + // ... |
| 62 | ++ "@reason-react-native/__template__" |
| 63 | + ], |
| 64 | + //... |
| 65 | +} |
| 66 | +``` |
| 67 | + |
| 68 | +## Usage |
| 69 | + |
| 70 | +### Types |
| 71 | + |
| 72 | +#### `ReactNativeSomething.t` |
| 73 | + |
| 74 | +... |
| 75 | + |
| 76 | +### Methods |
| 77 | + |
| 78 | +#### `ReactNativeSomething.method` |
| 79 | + |
| 80 | +... |
| 81 | + |
| 82 | +--- |
| 83 | + |
| 84 | +## Changelog |
| 85 | + |
| 86 | +Check the [changelog](./CHANGELOG.md) for more informations about recent |
| 87 | +releases. |
| 88 | + |
| 89 | +--- |
| 90 | + |
| 91 | +## Contribute |
| 92 | + |
| 93 | +Read the |
| 94 | +[contribution guidelines](https://github.com/reason-react-native/.github/blob/master/CONTRIBUTING.md) |
| 95 | +before contributing. |
| 96 | + |
| 97 | +## Code of Conduct |
| 98 | + |
| 99 | +We want this community to be friendly and respectful to each other. Please read |
| 100 | +[our full code of conduct](https://github.com/reason-react-native/.github/blob/master/CODE_OF_CONDUCT.md) |
| 101 | +so that you can understand what actions will and will not be tolerated. |
0 commit comments