Skip to content

Commit

Permalink
fix: HS-175: Added external services and brought parity to setup (#56)
Browse files Browse the repository at this point in the history
  • Loading branch information
ArushKapoorJuspay authored Dec 7, 2023
1 parent 9ab922f commit 5d62d5c
Showing 1 changed file with 19 additions and 18 deletions.
37 changes: 19 additions & 18 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -101,34 +101,25 @@ First install all the node modules by running the following command
npm install
```

Replace the placeholders in /Hyperswitch-react-demo-app/.env publishable key and secret key

```
HYPERSWITCH_PUBLISHABLE_KEY=<GET_THIS_FROM_DASHBOARD>
HYPERSWITCH_SECRET_KEY=<GET_THIS_FROM_DASHBOARD>
```

In the package json file you can see the various scripts you can run.
To start compiling the Rescript code, run the following command. Whenever there is a change in the Rescript code, the compiler will build its adjacent JS code which will be consumed.

```bash
npm run re:start
```

Start the webpack development server by running this command. This will trigger webpack to build a `dist` folder which will contain all the assets and serve it to port localhost:9050 (which you can change from within `webpack.common.js`)
Once the installation is successful, you can run the app with the following command -

```bash
npm run start
npm run start:dev
```

You will now get the url http://localhost:9050/HyperLoader.js, which is the script tag.
This will trigger a build of the project. On a successful build, you should see a message `Compiled successfully` in your terminal.

To see your Web Client functioning you can run the command below, this will open up a playground in which your immediate changes should reflect as you proceed with your development.
Now you can proceed with launching the playground. The playground is a demo app where you can test your payments. In a separate terminal, run the following command to start the app on your local machine.

```bash
npm run start:playground
```

This step will prompt you to enter 2 details -

- <strong>Publishable Key</strong> - This is a public key that resides on your client side for authentication
- <strong>Secret Key</strong> - This is the API key which should only be restricted to your app server

### About Env Configs

For ease of development and deployment there are configs in /Hyperswitch-react-demo-app/.env
Expand Down Expand Up @@ -202,6 +193,16 @@ Please refer to our [FAQs page][faqs].

[faqs]: https://hyperswitch.io/docs/devSupport

### External Services

- Braintree
- Trustpay
- Sentry
- ApplePay
- GooglePay
- Klarna
- Kount

<!--
## Documentation
Expand Down

0 comments on commit 5d62d5c

Please sign in to comment.