Skip to content

Commit e66db86

Browse files
committed
2 parents 7b09213 + 5e84b54 commit e66db86

1 file changed

Lines changed: 19 additions & 12 deletions

File tree

README.md

Lines changed: 19 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -179,32 +179,37 @@ Protocol fees collected on mint and liquidation events (configurable via protoco
179179
### Prerequisites
180180

181181
- [Aiken](https://aiken-lang.org) v1.1.19
182+
- Node.js v18+
182183

183184
```bash
184185
aikup install v1.1.19
185186
```
186187

187-
### Build
188+
### On-chain contracts
188189

189190
```bash
190191
cd on-chain
191-
aiken build
192+
aiken build # compiles → plutus.json
193+
aiken check # runs all 25 unit tests
192194
```
193195

194-
This compiles the contracts and generates `on-chain/plutus.json` (the Plutus blueprint).
195-
196-
### Run tests
196+
### Frontend
197197

198198
```bash
199-
cd on-chain
200-
aiken check
199+
cd frontend
200+
npm install
201+
npm run dev
201202
```
202203

203-
All 25 unit tests in `lib/utils.ak` cover:
204-
- `health_ratio` — collateral/debt ratio calculation
205-
- `can_adjust` / `is_liquidatable` — position health gates
206-
- `liquidator_payout` / `protocol_payout` — ADA distribution on liquidation
207-
- `compute_expected_synth_amount` — ADA → synth USD conversion (mint and burn directions)
204+
Opens at `http://localhost:5173`
205+
206+
### Backend
207+
208+
```bash
209+
cd backend
210+
npm install
211+
npm run dev
212+
```
208213

209214
### Project structure
210215

@@ -217,6 +222,8 @@ on-chain/
217222
types/
218223
cdp.ak # CdpDatum type
219224
aiken.toml # Dependencies
225+
frontend/ # Vite + React UI
226+
backend/ # TypeScript API server
220227
```
221228

222229
---

0 commit comments

Comments
 (0)