Skip to content

Commit

Permalink
update JS instructions (#960)
Browse files Browse the repository at this point in the history
Improve develop instructions for the JS client

---------

Co-authored-by: Pascal M <[email protected]>
Co-authored-by: Hammad Bashir <[email protected]>
  • Loading branch information
3 people authored Sep 7, 2023
1 parent 747f7c6 commit 3241de7
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions clients/js/DEVELOP.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,18 +5,24 @@ This readme is helpful for local dev.
### Prereqs:

- Make sure you have Java installed (for the generator). You can download it from [java.com](https://java.com)
- Make sure you set ALLOW_RESET=True for your Docker Container. If you don't do this, tests won't pass.
```
environment:
- IS_PERSISTENT=TRUE
- ALLOW_RESET=True
```
- Make sure you are running the docker backend at localhost:8000 (\*there is probably a way to stand up the fastapi server by itself and programmatically in the loop of generating this, but not prioritizing it for now. It may be important for the release)

### Generating

1. `yarn` to install deps
2. `yarn genapi-zsh` if you have zsh
2. `yarn genapi`
3. Examples are in the `examples` folder. There is one for the browser and one for node. Run them with `yarn dev`, eg `cd examples/browser && yarn dev`

### Running test

`yarn test` will launch a test docker backend.
`yarn test:run` will run against the docker backend you have running. But CAUTION, it will delete data.
`yarn test` will launch a test docker backend, run a db cleanup and run tests.
`yarn test:run` will run against the docker backend you have running. But CAUTION, it will delete data. This is the easiest and fastest way to run tests.

### Pushing to npm

Expand Down

0 comments on commit 3241de7

Please sign in to comment.