https://github.com/bamlab/react-native-stripe-sca
Stripe integration for react-native with SCA support
https://github.com/bamlab/react-native-stripe-sca
Last synced: 4 months ago
JSON representation
Stripe integration for react-native with SCA support
- Host: GitHub
- URL: https://github.com/bamlab/react-native-stripe-sca
- Owner: bamlab
- Created: 2019-08-01T18:06:09.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2023-01-07T08:19:56.000Z (over 3 years ago)
- Last Synced: 2025-06-26T03:05:13.584Z (about 1 year ago)
- Language: Ruby
- Size: 4.84 MB
- Stars: 4
- Watchers: 3
- Forks: 0
- Open Issues: 40
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
Awesome Lists containing this project
README
React Native Stripe SCA
Stripe Payment-Intent and Setup-Intent react-native bridges.
## Commands
TSDX scaffolds your new library inside `/src`, and also sets up a [Parcel-based](https://parceljs.org) playground for it inside `/example`.
The recommended workflow is to run TSDX in one terminal:
```
npm start # or yarn start
```
This builds to `/dist` and runs the project in watch mode so any edits you save inside `src` causes a rebuild to `/dist`.
Then run the example inside another:
```
cd example
npm i # or yarn to install dependencies
npm start # or yarn start
```
The default example imports and live reloads whatever is in `/dist`, so if you are seeing an out of date component, make sure TSDX is running in watch mode like we recommend above. **No symlinking required**, [we use Parcel's aliasing](https://github.com/palmerhq/tsdx/pull/88/files).
To do a one-off build, use `npm run build` or `yarn build`.
To run tests, use `npm test` or `yarn test`.
## Configuration
Code quality is [set up for you](https://github.com/palmerhq/tsdx/pull/45/files) with `prettier`, `husky`, and `lint-staged`. Adjust the respective fields in `package.json` accordingly.
### Jest
Jest tests are set up to run with `npm test` or `yarn test`. This runs the test watcher (Jest) in an interactive mode. By default, runs tests related to files changed since the last commit.
#### Setup Files
This is the folder structure we set up for you:
```
/example
index.html
index.tsx # test your component here in a demo app
package.json
tsconfig.json
/src
index.tsx # EDIT THIS
/test
blah.test.tsx # EDIT THIS
.gitignore
package.json
README.md # EDIT THIS
tsconfig.json
```
## Continuous Integration
### Travis
_to be completed_
### Circle
_to be completed_
## Optimizations
Please see the main `tsdx` [optimizations docs](https://github.com/palmerhq/tsdx#optimizations). In particular, know that you can take advantage of development-only optimizations:
```js
// ./types/index.d.ts
declare var __DEV__: boolean;
// inside your code...
if (__DEV__) {
console.log('foo');
}
```
You can also choose to install and use [invariant](https://github.com/palmerhq/tsdx#invariant) and [warning](https://github.com/palmerhq/tsdx#warning) functions.