Problem
Running npx tsc --noEmit produces 7 TypeScript errors
across agent.ts, examples/, and lib/buildTransaction.ts.
This means the package cannot be safely type-checked,
breaking IDE integration and CI pipelines.
Errors
- agent.ts: invalid Server import from @stellar/stellar-sdk
- agent.ts: TS2367 non-overlapping string comparisons
- agent.ts: untyped balance inference
- examples/: implicit any in catch blocks
- lib/buildTransaction.ts: string equivalence type errors
Fix
- Correct Horizon.Server import pattern
- Add Network type union, fix comparisons
- Explicit types on balance variables
- Typed catch blocks in examples/
- Type guards in buildTransaction.ts
I have a working fix with 0 tsc errors and all 28 tests
still passing. Happy to open a PR.
Problem
Running
npx tsc --noEmitproduces 7 TypeScript errorsacross agent.ts, examples/, and lib/buildTransaction.ts.
This means the package cannot be safely type-checked,
breaking IDE integration and CI pipelines.
Errors
Fix
I have a working fix with 0 tsc errors and all 28 tests
still passing. Happy to open a PR.