run prettier formatter on some readme files

This commit is contained in:
Simon Laux
2024-11-02 14:53:49 +01:00
committed by Simon Laux
parent c4d849a502
commit 1ac520439b
2 changed files with 11 additions and 8 deletions

View File

@@ -16,6 +16,7 @@ We also include a JavaScript and TypeScript client for the JSON-RPC API. The sou
The package includes a JavaScript/TypeScript client which is partially auto-generated through the JSON-RPC library used by this crate ([yerpc](https://github.com/chatmail/yerpc)). Find the source in the [`typescript`](typescript) folder.
To use it locally, first install the dependencies and compile the TypeScript code to JavaScript:
```sh
cd typescript
npm install
@@ -32,18 +33,20 @@ import { C } from "@deltachat/jsonrpc-client";
const dc = await startDeltaChat("deltachat-data");
console.log(await dc.rpc.getSystemInfo());
const accounts = await dc.rpc.getAllAccounts()
console.log('accounts', accounts)
dc.close()
const accounts = await dc.rpc.getAllAccounts();
console.log("accounts", accounts);
dc.close();
```
##### Generate TypeScript/JavaScript documentation
A script is included to build autogenerated documentation, which includes all RPC methods:
```sh
cd typescript
npm run docs
```
Then open the [`typescript/docs`](typescript/docs) folder in a web browser.
## Development