Rewrite store JSDoc, split quote/order into modules, and generate typed API docs
- Rewrite JSDoc across all store methods to document the actual async methods (real params, returns, throws) instead of the internal wrappers - Split quote/order into individual module files backed by shared manifestDoc helpers; remove the createStore factory and thin wrappers - Deduplicate manifest line helpers into src/store/manifestLines.js - Extend generate-api-doc.js to render parameter/return/throws types and emit per-namespace API.<module>.md files with an API.md index - Regenerate all API docs
This commit is contained in:
@@ -8,6 +8,19 @@ This document is auto-generated from the JSDoc comments in `src/store` by runnin
|
||||
|
||||
Adds a company user linking a company to a Google auth account.
|
||||
|
||||
**Parameters**
|
||||
|
||||
| Name | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| `companyId` | `number` | The id of the company. |
|
||||
| `googleAuthId` | `number` | The id of the Google auth account. |
|
||||
|
||||
**Returns**
|
||||
|
||||
`Promise<number>` — The id of the created company user link.
|
||||
|
||||
**Example**
|
||||
|
||||
```js
|
||||
const id = await store.companyuser.add(1, 42);
|
||||
// => 7
|
||||
@@ -19,6 +32,18 @@ const id = await store.companyuser.add(1, 42);
|
||||
|
||||
Deletes a company user link by its id.
|
||||
|
||||
**Parameters**
|
||||
|
||||
| Name | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| `id` | `number` | The id of the company user link to delete. |
|
||||
|
||||
**Returns**
|
||||
|
||||
`Promise<void>`
|
||||
|
||||
**Example**
|
||||
|
||||
```js
|
||||
await store.companyuser.delete(7);
|
||||
```
|
||||
@@ -29,6 +54,18 @@ await store.companyuser.delete(7);
|
||||
|
||||
Returns the company user ids associated with the given email address.
|
||||
|
||||
**Parameters**
|
||||
|
||||
| Name | Type | Description |
|
||||
| --- | --- | --- |
|
||||
| `email` | `string` | The email address. |
|
||||
|
||||
**Returns**
|
||||
|
||||
`Promise<Array<number>>` — The company user ids.
|
||||
|
||||
**Example**
|
||||
|
||||
```js
|
||||
const ids = await store.companyuser.getByEmail('user@example.com');
|
||||
// => [1, 2, 3]
|
||||
|
||||
Reference in New Issue
Block a user