embedoc 0.14.11 → 0.14.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -18,7 +18,7 @@ and can read where each property was defined with [`InlineDatasource.getMeta`](#
18
18
 
19
19
  #### Implements
20
20
 
21
- - `Datasource`
21
+ - [`Datasource`](#datasource)
22
22
 
23
23
  #### Properties
24
24
 
@@ -53,7 +53,7 @@ Returns all data or filters by simple conditions
53
53
 
54
54
  ###### Returns
55
55
 
56
- `Promise<QueryResult>`
56
+ `Promise<`[`QueryResult`](#queryresult)`>`
57
57
 
58
58
  ***
59
59
 
@@ -69,7 +69,7 @@ Get all data - returns array for Datasource interface compatibility
69
69
 
70
70
  ###### Returns
71
71
 
72
- `Promise<QueryResult>`
72
+ `Promise<`[`QueryResult`](#queryresult)`>`
73
73
 
74
74
  ***
75
75
 
@@ -162,7 +162,7 @@ Get location metadata for a specific property definition
162
162
 
163
163
  ###### Returns
164
164
 
165
- `InlineDefinitionLocation | null`
165
+ [`InlineDefinitionLocation`](#inlinedefinitionlocation)`| null`
166
166
 
167
167
  Location metadata or null if not found
168
168
 
@@ -186,7 +186,7 @@ Get all definition locations with relative paths calculated
186
186
 
187
187
  ###### Returns
188
188
 
189
- `InlineDefinitionLocation[]`
189
+ [`InlineDefinitionLocation`](#inlinedefinitionlocation)`[]`
190
190
 
191
191
  Array of all definition locations (sorted by propertyPath)
192
192
 
@@ -215,7 +215,7 @@ Location metadata for an inline definition
215
215
 
216
216
  ### ApiMarkdownOptions
217
217
 
218
- Defined in: [helpers/api-markdown.ts:21](https://github.com/foo-ogawa/embedoc/blob/main/src/helpers/api-markdown.ts#L21)
218
+ Defined in: [helpers/api-markdown.ts:22](https://github.com/foo-ogawa/embedoc/blob/main/src/helpers/api-markdown.ts#L22)
219
219
 
220
220
  Options for [`renderApiIndex`](#renderapiindex) and [`renderApiPage`](#renderapipage).
221
221
 
@@ -223,16 +223,15 @@ Options for [`renderApiIndex`](#renderapiindex) and [`renderApiPage`](#renderapi
223
223
 
224
224
  | Property | Type | Description | Defined in |
225
225
  | ------ | ------ | ------ | ------ |
226
- | <a id="ownfilekinds"></a> `ownFileKinds?` | `ApiSymbolKind[]` | Kinds whose symbols get a page of their own at `<kindDir>/<name>.md` (e.g. `['class', 'interface', 'function']`). Symbols of the other kinds are written in full on the index page. Default: none, so everything is on the index. | [helpers/api-markdown.ts:27](https://github.com/foo-ogawa/embedoc/blob/main/src/helpers/api-markdown.ts#L27) |
227
- | <a id="categoryorder"></a> `categoryOrder?` | `string[]` | Order of category headings. `*` marks where the categories that are not listed go (alphabetically); without `*` they go last. Symbols without a `@category` tag are in the category `Other`. Category headings appear only in kind groups where at least one symbol has a category. | [helpers/api-markdown.ts:34](https://github.com/foo-ogawa/embedoc/blob/main/src/helpers/api-markdown.ts#L34) |
228
- | <a id="indexfile"></a> `indexFile?` | `string` | File name of the index page, for links from symbol pages (default: `README.md`). | [helpers/api-markdown.ts:36](https://github.com/foo-ogawa/embedoc/blob/main/src/helpers/api-markdown.ts#L36) |
229
- | <a id="headinglevel"></a> `headingLevel?` | `number` | Heading level of the kind groups on the index page (default: 2). | [helpers/api-markdown.ts:38](https://github.com/foo-ogawa/embedoc/blob/main/src/helpers/api-markdown.ts#L38) |
226
+ | <a id="categoryorder"></a> `categoryOrder?` | `string[]` | Order of category headings. `*` marks where the categories that are not listed go (alphabetically); without `*` they go last. Symbols without a `@category` tag are in the category `Other`. Category headings appear only in kind groups where at least one symbol has a category. | [helpers/api-markdown.ts:29](https://github.com/foo-ogawa/embedoc/blob/main/src/helpers/api-markdown.ts#L29) |
227
+ | <a id="indexfile"></a> `indexFile?` | `string` | File name of the index page, for links from symbol pages (default: `README.md`). | [helpers/api-markdown.ts:31](https://github.com/foo-ogawa/embedoc/blob/main/src/helpers/api-markdown.ts#L31) |
228
+ | <a id="headinglevel"></a> `headingLevel?` | `number` | Heading level of the kind groups on the index page (default: 2). | [helpers/api-markdown.ts:33](https://github.com/foo-ogawa/embedoc/blob/main/src/helpers/api-markdown.ts#L33) |
230
229
 
231
230
  ***
232
231
 
233
232
  ### DatasourceConfig
234
233
 
235
- Defined in: [types/index.ts:54](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L54)
234
+ Defined in: [types/index.ts:60](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L60)
236
235
 
237
236
  Datasource configuration.
238
237
 
@@ -245,24 +244,24 @@ in their `create()` method.
245
244
 
246
245
  | Index | Type | Description | Defined in |
247
246
  | ------ | ------ | ------ | ------ |
248
- | <a id="key-string"></a> `[key: string]` | `unknown` | | [types/index.ts:61](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L61) |
247
+ | <a id="key-string"></a> `[key: string]` | `unknown` | | [types/index.ts:67](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L67) |
249
248
 
250
249
  #### Properties
251
250
 
252
251
  | Property | Type | Description | Defined in |
253
252
  | ------ | ------ | ------ | ------ |
254
- | <a id="type"></a> `type` | `string` | | [types/index.ts:55](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L55) |
255
- | <a id="path"></a> `path?` | `string` | | [types/index.ts:56](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L56) |
256
- | <a id="pattern"></a> `pattern?` | `string` | | [types/index.ts:57](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L57) |
257
- | <a id="query"></a> `query?` | `string` | | [types/index.ts:58](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L58) |
258
- | <a id="encoding"></a> `encoding?` | `string` | | [types/index.ts:59](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L59) |
259
- | <a id="generators"></a> `generators?` | `GeneratorConfig[]` | | [types/index.ts:60](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L60) |
253
+ | <a id="type"></a> `type` | `string` | | [types/index.ts:61](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L61) |
254
+ | <a id="path"></a> `path?` | `string` | | [types/index.ts:62](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L62) |
255
+ | <a id="pattern"></a> `pattern?` | `string` | | [types/index.ts:63](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L63) |
256
+ | <a id="query"></a> `query?` | `string` | | [types/index.ts:64](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L64) |
257
+ | <a id="encoding"></a> `encoding?` | `string` | | [types/index.ts:65](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L65) |
258
+ | <a id="generators"></a> `generators?` | `GeneratorConfig[]` | | [types/index.ts:66](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L66) |
260
259
 
261
260
  ***
262
261
 
263
262
  ### Datasource
264
263
 
265
- Defined in: [types/index.ts:211](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L211)
264
+ Defined in: [types/index.ts:217](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L217)
266
265
 
267
266
  Datasource interface for accessing external data.
268
267
 
@@ -302,7 +301,7 @@ const allData = await ds.getAll();
302
301
 
303
302
  | Property | Type | Description | Defined in |
304
303
  | ------ | ------ | ------ | ------ |
305
- | <a id="type"></a> `type` (readonly) | `string` | Datasource type identifier. One of: 'sqlite', 'csv', 'json', 'yaml', 'glob', 'typescript', 'inline' | [types/index.ts:216](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L216) |
304
+ | <a id="type"></a> `type` (readonly) | `string` | Datasource type identifier. One of: 'sqlite', 'csv', 'json', 'yaml', 'glob', 'typescript', 'inline' | [types/index.ts:222](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L222) |
306
305
 
307
306
  #### Methods
308
307
 
@@ -312,7 +311,7 @@ const allData = await ds.getAll();
312
311
  query(sql: string, params?: unknown[]): Promise<QueryResult>;
313
312
  ```
314
313
 
315
- Defined in: [types/index.ts:248](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L248)
314
+ Defined in: [types/index.ts:254](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L254)
316
315
 
317
316
  Execute a parameterized query on the datasource.
318
317
 
@@ -349,7 +348,7 @@ const filtered = await ds.query(
349
348
 
350
349
  ###### Returns
351
350
 
352
- `Promise<QueryResult>`
351
+ `Promise<`[`QueryResult`](#queryresult)`>`
353
352
 
354
353
  Promise resolving to an array of records
355
354
 
@@ -361,7 +360,7 @@ Promise resolving to an array of records
361
360
  getAll(): Promise<QueryResult>;
362
361
  ```
363
362
 
364
- Defined in: [types/index.ts:267](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L267)
363
+ Defined in: [types/index.ts:273](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L273)
365
364
 
366
365
  Get all data from the datasource.
367
366
 
@@ -380,7 +379,7 @@ const config = await ctx.datasources['config'].getAll();
380
379
 
381
380
  ###### Returns
382
381
 
383
- `Promise<QueryResult>`
382
+ `Promise<`[`QueryResult`](#queryresult)`>`
384
383
 
385
384
  Promise resolving to an array of all records
386
385
 
@@ -388,7 +387,7 @@ Promise resolving to an array of all records
388
387
 
389
388
  ### CustomDatasourceDefinition
390
389
 
391
- Defined in: [types/index.ts:293](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L293)
390
+ Defined in: [types/index.ts:299](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L299)
392
391
 
393
392
  Definition for a custom datasource type.
394
393
 
@@ -408,23 +407,23 @@ return a [`Datasource`](#datasource) instance.
408
407
  create(config: DatasourceConfig): Promise<Datasource>;
409
408
  ```
410
409
 
411
- Defined in: [types/index.ts:294](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L294)
410
+ Defined in: [types/index.ts:300](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L300)
412
411
 
413
412
  ###### Parameters
414
413
 
415
414
  | Parameter | Type |
416
415
  | ------ | ------ |
417
- | `config` | `DatasourceConfig` |
416
+ | `config` | [`DatasourceConfig`](#datasourceconfig) |
418
417
 
419
418
  ###### Returns
420
419
 
421
- `Promise<Datasource>`
420
+ `Promise<`[`Datasource`](#datasource)`>`
422
421
 
423
422
  ***
424
423
 
425
424
  ### TypeScriptDatasourceConfig
426
425
 
427
- Defined in: [types/index.ts:323](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L323)
426
+ Defined in: [types/index.ts:329](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L329)
428
427
 
429
428
  Configuration of the built-in `typescript` datasource.
430
429
 
@@ -438,27 +437,28 @@ datasources.
438
437
 
439
438
  #### Extends
440
439
 
441
- - `DatasourceConfig`
440
+ - [`DatasourceConfig`](#datasourceconfig)
442
441
 
443
442
  #### Properties
444
443
 
445
444
  | Property | Type | Description | Defined in |
446
445
  | ------ | ------ | ------ | ------ |
447
- | <a id="type"></a> `type` | `'typescript'` | | [types/index.ts:324](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L324) |
448
- | <a id="entry_points"></a> `entry_points` | `string[]` | Entry point files whose exports form the public API. | [types/index.ts:326](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L326) |
449
- | <a id="tsconfig"></a> `tsconfig?` | `string` | tsconfig.json to compile with (default: the nearest one above the first entry point). | [types/index.ts:328](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L328) |
450
- | <a id="exclude_internal"></a> `exclude_internal?` | `boolean` | Leave out symbols and members tagged `@internal` (default: true). | [types/index.ts:330](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L330) |
451
- | <a id="exclude_private"></a> `exclude_private?` | `boolean` | Leave out `private` and `#private` class members (default: true). | [types/index.ts:332](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L332) |
452
- | <a id="exclude_externals"></a> `exclude_externals?` | `boolean` | Leave out symbols declared in external libraries such as node_modules (default: true). | [types/index.ts:334](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L334) |
453
- | <a id="source_link_template"></a> `source_link_template?` | `string` | Source link URL with the placeholders `{path}` (relative to the working directory), `{line}` and `{gitRevision}`. No link is produced without it. | [types/index.ts:339](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L339) |
454
- | <a id="git_revision"></a> `git_revision?` | `string` | Value of `{gitRevision}`. Required when the template uses `{gitRevision}`. | [types/index.ts:341](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L341) |
455
- | <a id="sort"></a> `sort?` | `'source-order' | 'alphabetical'` | Record order: `source-order` (file path, then position) or `alphabetical` (default: source-order). | [types/index.ts:343](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L343) |
446
+ | <a id="type"></a> `type` | `'typescript'` | | [types/index.ts:330](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L330) |
447
+ | <a id="entry_points"></a> `entry_points` | `string[]` | Entry point files whose exports form the public API. | [types/index.ts:332](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L332) |
448
+ | <a id="tsconfig"></a> `tsconfig?` | `string` | tsconfig.json to compile with (default: the nearest one above the first entry point). | [types/index.ts:334](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L334) |
449
+ | <a id="exclude_internal"></a> `exclude_internal?` | `boolean` | Leave out symbols and members tagged `@internal` (default: true). | [types/index.ts:336](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L336) |
450
+ | <a id="exclude_private"></a> `exclude_private?` | `boolean` | Leave out `private` and `#private` class members (default: true). | [types/index.ts:338](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L338) |
451
+ | <a id="exclude_externals"></a> `exclude_externals?` | `boolean` | Leave out symbols declared in external libraries such as node_modules (default: true). | [types/index.ts:340](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L340) |
452
+ | <a id="source_link_template"></a> `source_link_template?` | `string` | Source link URL with the placeholders `{path}` (relative to the working directory), `{line}` and `{gitRevision}`. No link is produced without it. | [types/index.ts:345](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L345) |
453
+ | <a id="git_revision"></a> `git_revision?` | `string` | Value of `{gitRevision}`. Required when the template uses `{gitRevision}`. | [types/index.ts:347](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L347) |
454
+ | <a id="sort"></a> `sort?` | `'source-order' \| 'alphabetical'` | Record order: `source-order` (file path, then position) or `alphabetical` (default: source-order). | [types/index.ts:349](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L349) |
455
+ | <a id="pages"></a> `pages?` | [`ApiSymbolKind`](#apisymbolkind)`[]` | Kinds whose symbols get a page of their own (`page` = `<kindDir>/<name>.md`, `hasPage` = true), e.g. `[class, interface, function]`. Default: none. The renderers and the generator read `page` / `hasPage`, so this list is the only place that decides which symbols have pages. | [types/index.ts:356](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L356) |
456
456
 
457
457
  ***
458
458
 
459
459
  ### MarkdownHelper
460
460
 
461
- Defined in: [types/index.ts:516](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L516)
461
+ Defined in: [types/index.ts:540](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L540)
462
462
 
463
463
  Helper interface for generating Markdown content.
464
464
 
@@ -494,7 +494,7 @@ export default defineEmbed({
494
494
  table(headers: string[], rows: (string | number | boolean | null | undefined)[][]): string;
495
495
  ```
496
496
 
497
- Defined in: [types/index.ts:540](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L540)
497
+ Defined in: [types/index.ts:564](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L564)
498
498
 
499
499
  Generate a Markdown table.
500
500
 
@@ -520,7 +520,7 @@ ctx.markdown.table(
520
520
  | Parameter | Type | Description |
521
521
  | ------ | ------ | ------ |
522
522
  | `headers` | `string[]` | Array of column header strings |
523
- | `rows` | `(string | number | boolean | null | undefined)[][]` | 2D array of cell values (each inner array is a row) |
523
+ | `rows` | `(string \| number \| boolean \| null \| undefined)[][]` | 2D array of cell values (each inner array is a row) |
524
524
 
525
525
  ###### Returns
526
526
 
@@ -536,7 +536,7 @@ Formatted Markdown table string
536
536
  list(items: string[], ordered?: boolean): string;
537
537
  ```
538
538
 
539
- Defined in: [types/index.ts:566](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L566)
539
+ Defined in: [types/index.ts:590](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L590)
540
540
 
541
541
  Generate a Markdown list.
542
542
 
@@ -579,7 +579,7 @@ Formatted Markdown list string
579
579
  codeBlock(code: string, language?: string): string;
580
580
  ```
581
581
 
582
- Defined in: [types/index.ts:584](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L584)
582
+ Defined in: [types/index.ts:608](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L608)
583
583
 
584
584
  Generate a fenced code block.
585
585
 
@@ -614,7 +614,7 @@ Formatted Markdown code block string
614
614
  link(text: string, url: string): string;
615
615
  ```
616
616
 
617
- Defined in: [types/index.ts:599](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L599)
617
+ Defined in: [types/index.ts:623](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L623)
618
618
 
619
619
  Generate a Markdown link.
620
620
 
@@ -646,7 +646,7 @@ Formatted Markdown link string
646
646
  heading(text: string, level?: number): string;
647
647
  ```
648
648
 
649
- Defined in: [types/index.ts:614](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L614)
649
+ Defined in: [types/index.ts:638](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L638)
650
650
 
651
651
  Generate a Markdown heading.
652
652
 
@@ -678,7 +678,7 @@ Formatted Markdown heading string
678
678
  bold(text: string): string;
679
679
  ```
680
680
 
681
- Defined in: [types/index.ts:628](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L628)
681
+ Defined in: [types/index.ts:652](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L652)
682
682
 
683
683
  Wrap text in bold formatting.
684
684
 
@@ -709,7 +709,7 @@ Bold formatted string
709
709
  italic(text: string): string;
710
710
  ```
711
711
 
712
- Defined in: [types/index.ts:642](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L642)
712
+ Defined in: [types/index.ts:666](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L666)
713
713
 
714
714
  Wrap text in italic formatting.
715
715
 
@@ -740,7 +740,7 @@ Italic formatted string
740
740
  checkbox(checked: boolean): string;
741
741
  ```
742
742
 
743
- Defined in: [types/index.ts:656](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L656)
743
+ Defined in: [types/index.ts:680](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L680)
744
744
 
745
745
  Generate a checkbox character.
746
746
 
@@ -767,7 +767,7 @@ Checkbox character ('✔' if checked, '' if not)
767
767
 
768
768
  ### EmbedContext
769
769
 
770
- Defined in: [types/index.ts:692](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L692)
770
+ Defined in: [types/index.ts:716](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L716)
771
771
 
772
772
  Context object passed to an embed's render function.
773
773
 
@@ -806,18 +806,18 @@ export default defineEmbed({
806
806
 
807
807
  | Property | Type | Description | Defined in |
808
808
  | ------ | ------ | ------ | ------ |
809
- | <a id="params"></a> `params` | `Record<string, string>` | Parameters from the marker attributes.<br><br>Parsed from the marker syntax: `<!--@embedoc:embed_name param1="value1" param2="value2"-->`<br><br>Variable references (`${...}`) are resolved before passing to the embed. | [types/index.ts:708](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L708) |
810
- | <a id="frontmatter"></a> `frontmatter` | `Record<string, unknown>` | Frontmatter data from the document.<br><br>Parsed from YAML frontmatter at the top of the document. | [types/index.ts:726](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L726) |
811
- | <a id="datasources"></a> `datasources` | `Record<string, Datasource>` | Map of configured datasources.<br><br>Keys are datasource names from `embedoc.config.yaml`. Includes both external datasources and inline datasources defined in the document. | [types/index.ts:746](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L746) |
812
- | <a id="markdown"></a> `markdown` | `MarkdownHelper` | Markdown generation helper.<br><br>Always available. Provides methods for creating tables, lists, code blocks, links, and other Markdown elements. | [types/index.ts:756](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L756) |
813
- | <a id="filepath"></a> `filePath` | `string` | Absolute path to the current file being processed.<br><br>Useful for generating relative links or file references. | [types/index.ts:769](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L769) |
814
- | <a id="existingcontent"></a> `existingContent?` | `string` | Existing content between the markers (before replacement).<br><br>Useful for error recovery - return `existingContent` when data sources are unavailable to preserve the previous state. | [types/index.ts:788](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L788) |
809
+ | <a id="params"></a> `params` | `Record<string, string>` | Parameters from the marker attributes.<br><br>Parsed from the marker syntax: `<!--@embedoc:embed_name param1="value1" param2="value2"-->`<br><br>Variable references (`${...}`) are resolved before passing to the embed.<br><br>**Example** `// Marker: <!--@embedoc:table_columns id="users" schema="public"-->` `const { id, schema } = ctx.params;` `// id = "users", schema = "public"` | [types/index.ts:732](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L732) |
810
+ | <a id="frontmatter"></a> `frontmatter` | `Record<string, unknown>` | Frontmatter data from the document.<br><br>Parsed from YAML frontmatter at the top of the document.<br><br>**Example** `// Document frontmatter:` `// ---` `// doc_id: "users"` `// schema: "public"` `// ---` `const docId = ctx.frontmatter['doc_id'] as string;` | [types/index.ts:750](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L750) |
811
+ | <a id="datasources"></a> `datasources` | `Record<string,`[`Datasource`](#datasource)`>` | Map of configured datasources.<br><br>Keys are datasource names from `embedoc.config.yaml`. Includes both external datasources and inline datasources defined in the document.<br><br>**Example** `// Access SQLite datasource` `const db = ctx.datasources['metadata_db'];` `const rows = await db.query('SELECT * FROM users');` `// Access inline datasource` `const config = ctx.datasources['project_config'];` `const data = await config.getAll();` | [types/index.ts:770](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L770) |
812
+ | <a id="markdown"></a> `markdown` | [`MarkdownHelper`](#markdownhelper) | Markdown generation helper.<br><br>Always available. Provides methods for creating tables, lists, code blocks, links, and other Markdown elements.<br><br>**See** [`MarkdownHelper`](#markdownhelper) | [types/index.ts:780](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L780) |
813
+ | <a id="filepath"></a> `filePath` | `string` | Absolute path to the current file being processed.<br><br>Useful for generating relative links or file references.<br><br>**Example** `const dir = path.dirname(ctx.filePath);` `const relativePath = path.relative(dir, targetFile);` | [types/index.ts:793](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L793) |
814
+ | <a id="existingcontent"></a> `existingContent?` | `string` | Existing content between the markers (before replacement).<br><br>Useful for error recovery - return `existingContent` when data sources are unavailable to preserve the previous state.<br><br>**Example** `try {` `const data = await fetchFromDatabase();` `return { content: formatData(data) };` `} catch (error) {` `console.warn('Database unavailable, keeping existing content');` `return { content: ctx.existingContent ?? null };` `}` | [types/index.ts:812](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L812) |
815
815
 
816
816
  ***
817
817
 
818
818
  ### EmbedResult
819
819
 
820
- Defined in: [types/index.ts:803](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L803)
820
+ Defined in: [types/index.ts:827](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L827)
821
821
 
822
822
  Result object returned from an embed's render function.
823
823
 
@@ -835,13 +835,13 @@ export default defineEmbed({
835
835
 
836
836
  | Property | Type | Description | Defined in |
837
837
  | ------ | ------ | ------ | ------ |
838
- | <a id="content"></a> `content` | `string | null | undefined` | Generated content to insert between the markers.<br><br>This string replaces the existing content between the start and end markers in the document.<br><br>Return `null` or `undefined` to keep the existing content (useful for error recovery when data sources are unavailable). | [types/index.ts:813](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L813) |
838
+ | <a id="content"></a> `content` | `string \| null \| undefined` | Generated content to insert between the markers.<br><br>This string replaces the existing content between the start and end markers in the document.<br><br>Return `null` or `undefined` to keep the existing content (useful for error recovery when data sources are unavailable). | [types/index.ts:837](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L837) |
839
839
 
840
840
  ***
841
841
 
842
842
  ### EmbedDefinition
843
843
 
844
- Defined in: [types/index.ts:845](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L845)
844
+ Defined in: [types/index.ts:869](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L869)
845
845
 
846
846
  Embed definition interface.
847
847
 
@@ -876,7 +876,7 @@ export default defineEmbed({
876
876
 
877
877
  | Property | Type | Description | Defined in |
878
878
  | ------ | ------ | ------ | ------ |
879
- | <a id="dependson"></a> `dependsOn?` | `string[]` | List of datasource names this embed depends on.<br><br>Used for dependency tracking in incremental builds. When a datasource changes, all documents using embeds that depend on it will be rebuilt. | [types/index.ts:858](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L858) |
879
+ | <a id="dependson"></a> `dependsOn?` | `string[]` | List of datasource names this embed depends on.<br><br>Used for dependency tracking in incremental builds. When a datasource changes, all documents using embeds that depend on it will be rebuilt.<br><br>**Example** `dependsOn: ['metadata_db', 'api_endpoints']` | [types/index.ts:882](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L882) |
880
880
 
881
881
  #### Methods
882
882
 
@@ -886,7 +886,7 @@ export default defineEmbed({
886
886
  render(ctx: EmbedContext): Promise<EmbedResult>;
887
887
  ```
888
888
 
889
- Defined in: [types/index.ts:869](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L869)
889
+ Defined in: [types/index.ts:893](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L893)
890
890
 
891
891
  Render function that generates the embed content.
892
892
 
@@ -897,11 +897,11 @@ Receives the context object with parameters, datasources, and helpers.
897
897
 
898
898
  | Parameter | Type | Description |
899
899
  | ------ | ------ | ------ |
900
- | `ctx` | `EmbedContext` | The embed context |
900
+ | `ctx` | [`EmbedContext`](#embedcontext) | The embed context |
901
901
 
902
902
  ###### Returns
903
903
 
904
- `Promise<EmbedResult>`
904
+ `Promise<`[`EmbedResult`](#embedresult)`>`
905
905
 
906
906
  Promise resolving to the embed result with generated content
907
907
 
@@ -913,7 +913,7 @@ Promise resolving to the embed result with generated content
913
913
  type QueryResult = Record<string, unknown>[];
914
914
  ```
915
915
 
916
- Defined in: [types/index.ts:175](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L175)
916
+ Defined in: [types/index.ts:181](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L181)
917
917
 
918
918
  Query result returned from datasource operations.
919
919
 
@@ -938,7 +938,7 @@ users.forEach(user => {
938
938
  type InlineFormatParser = (content: string) => unknown;
939
939
  ```
940
940
 
941
- Defined in: [types/index.ts:306](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L306)
941
+ Defined in: [types/index.ts:312](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L312)
942
942
 
943
943
  Parser function for a custom inline datasource format.
944
944
 
@@ -963,7 +963,7 @@ type ApiSymbolKind = | 'namespace'
963
963
  | 'reference';
964
964
  ```
965
965
 
966
- Defined in: [types/index.ts:347](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L347)
966
+ Defined in: [types/index.ts:360](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L360)
967
967
 
968
968
  Kind of an exported API symbol. A `reference` is a second exported name of a symbol.
969
969
 
@@ -981,7 +981,7 @@ type ApiMemberKind = | 'constructor'
981
981
  | 'enum-member';
982
982
  ```
983
983
 
984
- Defined in: [types/index.ts:358](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L358)
984
+ Defined in: [types/index.ts:371](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L371)
985
985
 
986
986
  Kind of a member of a class, interface, object type or enum.
987
987
 
@@ -1002,7 +1002,7 @@ type ApiSource = {
1002
1002
  };
1003
1003
  ```
1004
1004
 
1005
- Defined in: [types/index.ts:368](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L368)
1005
+ Defined in: [types/index.ts:381](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L381)
1006
1006
 
1007
1007
  Where a declaration is in the source.
1008
1008
 
@@ -1010,10 +1010,10 @@ Where a declaration is in the source.
1010
1010
 
1011
1011
  | Property | Type | Description | Defined in |
1012
1012
  | ------ | ------ | ------ | ------ |
1013
- | <a id="file"></a> `file` | `string` | Path relative to the common directory of the entry points (for display). | [types/index.ts:370](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L370) |
1014
- | <a id="path"></a> `path` | `string` | Path relative to the working directory (the `{path}` of the link template). | [types/index.ts:372](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L372) |
1015
- | <a id="line"></a> `line` | `number` | 1-based line of the declaration name. | [types/index.ts:374](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L374) |
1016
- | <a id="url"></a> `url` | `string | null` | Link built from `source_link_template`, or null without a template. | [types/index.ts:376](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L376) |
1013
+ | <a id="file"></a> `file` | `string` | Path relative to the common directory of the entry points (for display). | [types/index.ts:383](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L383) |
1014
+ | <a id="path"></a> `path` | `string` | Path relative to the working directory (the `{path}` of the link template). | [types/index.ts:385](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L385) |
1015
+ | <a id="line"></a> `line` | `number` | 1-based line of the declaration name. | [types/index.ts:387](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L387) |
1016
+ | <a id="url"></a> `url` | `string \| null` | Link built from `source_link_template`, or null without a template. | [types/index.ts:389](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L389) |
1017
1017
 
1018
1018
  ***
1019
1019
 
@@ -1028,7 +1028,7 @@ type ApiTag = {
1028
1028
  };
1029
1029
  ```
1030
1030
 
1031
- Defined in: [types/index.ts:380](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L380)
1031
+ Defined in: [types/index.ts:393](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L393)
1032
1032
 
1033
1033
  A JSDoc block tag such as `@example`, `@deprecated` or `@see`.
1034
1034
 
@@ -1036,8 +1036,8 @@ A JSDoc block tag such as `@example`, `@deprecated` or `@see`.
1036
1036
 
1037
1037
  | Property | Type | Description | Defined in |
1038
1038
  | ------ | ------ | ------ | ------ |
1039
- | <a id="tag"></a> `tag` | `string` | Tag name without `@`. | [types/index.ts:382](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L382) |
1040
- | <a id="text"></a> `text` | `string` | Tag text. ``...`` inline tags are kept as written. | [types/index.ts:384](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L384) |
1039
+ | <a id="tag"></a> `tag` | `string` | Tag name without `@`. | [types/index.ts:395](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L395) |
1040
+ | <a id="text"></a> `text` | `string` | Tag text. ``...`` inline tags are kept as written. | [types/index.ts:397](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L397) |
1041
1041
 
1042
1042
  ***
1043
1043
 
@@ -1052,7 +1052,7 @@ type ApiTypeParameter = {
1052
1052
  };
1053
1053
  ```
1054
1054
 
1055
- Defined in: [types/index.ts:388](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L388)
1055
+ Defined in: [types/index.ts:401](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L401)
1056
1056
 
1057
1057
  A type parameter of a declaration or signature.
1058
1058
 
@@ -1060,10 +1060,10 @@ A type parameter of a declaration or signature.
1060
1060
 
1061
1061
  | Property | Type | Description | Defined in |
1062
1062
  | ------ | ------ | ------ | ------ |
1063
- | <a id="name"></a> `name` | `string` | | [types/index.ts:389](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L389) |
1064
- | <a id="constraint"></a> `constraint` | `string | null` | | [types/index.ts:390](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L390) |
1065
- | <a id="default"></a> `default` | `string | null` | | [types/index.ts:391](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L391) |
1066
- | <a id="description"></a> `description` | `string` | | [types/index.ts:392](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L392) |
1063
+ | <a id="name"></a> `name` | `string` | | [types/index.ts:402](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L402) |
1064
+ | <a id="constraint"></a> `constraint` | `string \| null` | | [types/index.ts:403](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L403) |
1065
+ | <a id="default"></a> `default` | `string \| null` | | [types/index.ts:404](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L404) |
1066
+ | <a id="description"></a> `description` | `string` | | [types/index.ts:405](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L405) |
1067
1067
 
1068
1068
  ***
1069
1069
 
@@ -1080,7 +1080,7 @@ type ApiParameter = {
1080
1080
  };
1081
1081
  ```
1082
1082
 
1083
- Defined in: [types/index.ts:396](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L396)
1083
+ Defined in: [types/index.ts:409](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L409)
1084
1084
 
1085
1085
  A parameter of a signature.
1086
1086
 
@@ -1088,12 +1088,12 @@ A parameter of a signature.
1088
1088
 
1089
1089
  | Property | Type | Description | Defined in |
1090
1090
  | ------ | ------ | ------ | ------ |
1091
- | <a id="name"></a> `name` | `string` | | [types/index.ts:397](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L397) |
1092
- | <a id="type"></a> `type` | `string` | | [types/index.ts:398](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L398) |
1093
- | <a id="optional"></a> `optional` | `boolean` | | [types/index.ts:399](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L399) |
1094
- | <a id="rest"></a> `rest` | `boolean` | | [types/index.ts:400](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L400) |
1095
- | <a id="defaultvalue"></a> `defaultValue` | `string | null` | | [types/index.ts:401](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L401) |
1096
- | <a id="description"></a> `description` | `string` | | [types/index.ts:402](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L402) |
1091
+ | <a id="name"></a> `name` | `string` | | [types/index.ts:410](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L410) |
1092
+ | <a id="type"></a> `type` | `string` | | [types/index.ts:411](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L411) |
1093
+ | <a id="optional"></a> `optional` | `boolean` | | [types/index.ts:412](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L412) |
1094
+ | <a id="rest"></a> `rest` | `boolean` | | [types/index.ts:413](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L413) |
1095
+ | <a id="defaultvalue"></a> `defaultValue` | `string \| null` | | [types/index.ts:414](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L414) |
1096
+ | <a id="description"></a> `description` | `string` | | [types/index.ts:415](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L415) |
1097
1097
 
1098
1098
  ***
1099
1099
 
@@ -1113,7 +1113,7 @@ type ApiSignature = {
1113
1113
  };
1114
1114
  ```
1115
1115
 
1116
- Defined in: [types/index.ts:406](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L406)
1116
+ Defined in: [types/index.ts:419](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L419)
1117
1117
 
1118
1118
  A call, construct, method or accessor signature.
1119
1119
 
@@ -1121,13 +1121,13 @@ A call, construct, method or accessor signature.
1121
1121
 
1122
1122
  | Property | Type | Description | Defined in |
1123
1123
  | ------ | ------ | ------ | ------ |
1124
- | <a id="code"></a> `code` | `string` | Declaration as code, e.g. `function f(a: string): void;`. | [types/index.ts:408](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L408) |
1125
- | <a id="summary"></a> `summary` | `string` | | [types/index.ts:409](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L409) |
1126
- | <a id="tags"></a> `tags` | `ApiTag[]` | | [types/index.ts:410](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L410) |
1127
- | <a id="typeparameters"></a> `typeParameters` | `ApiTypeParameter[]` | | [types/index.ts:411](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L411) |
1128
- | <a id="parameters"></a> `parameters` | `ApiParameter[]` | | [types/index.ts:412](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L412) |
1129
- | <a id="returns"></a> `returns` | `{ type: string; description: string } | null` | Return type and `@returns` text; null for constructors and setters. | [types/index.ts:414](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L414) |
1130
- | <a id="source"></a> `source` | `ApiSource` | | [types/index.ts:415](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L415) |
1124
+ | <a id="code"></a> `code` | `string` | Declaration as code, e.g. `function f(a: string): void;`. | [types/index.ts:421](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L421) |
1125
+ | <a id="summary"></a> `summary` | `string` | | [types/index.ts:422](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L422) |
1126
+ | <a id="tags"></a> `tags` | [`ApiTag`](#apitag)`[]` | | [types/index.ts:423](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L423) |
1127
+ | <a id="typeparameters"></a> `typeParameters` | [`ApiTypeParameter`](#apitypeparameter)`[]` | | [types/index.ts:424](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L424) |
1128
+ | <a id="parameters"></a> `parameters` | [`ApiParameter`](#apiparameter)`[]` | | [types/index.ts:425](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L425) |
1129
+ | <a id="returns"></a> `returns` | `{ type: string; description: string } \| null` | Return type and `@returns` text; null for constructors and setters. | [types/index.ts:427](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L427) |
1130
+ | <a id="source"></a> `source` | [`ApiSource`](#apisource) | | [types/index.ts:428](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L428) |
1131
1131
 
1132
1132
  ***
1133
1133
 
@@ -1152,7 +1152,7 @@ type ApiMember = {
1152
1152
  };
1153
1153
  ```
1154
1154
 
1155
- Defined in: [types/index.ts:419](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L419)
1155
+ Defined in: [types/index.ts:432](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L432)
1156
1156
 
1157
1157
  A member of a class, interface, object type alias or enum.
1158
1158
 
@@ -1160,18 +1160,18 @@ A member of a class, interface, object type alias or enum.
1160
1160
 
1161
1161
  | Property | Type | Description | Defined in |
1162
1162
  | ------ | ------ | ------ | ------ |
1163
- | <a id="name"></a> `name` | `string` | | [types/index.ts:420](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L420) |
1164
- | <a id="kind"></a> `kind` | `ApiMemberKind` | | [types/index.ts:421](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L421) |
1165
- | <a id="static"></a> `static` | `boolean` | | [types/index.ts:422](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L422) |
1166
- | <a id="readonly"></a> `readonly` | `boolean` | | [types/index.ts:423](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L423) |
1167
- | <a id="optional"></a> `optional` | `boolean` | | [types/index.ts:424](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L424) |
1168
- | <a id="protected"></a> `protected` | `boolean` | | [types/index.ts:425](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L425) |
1169
- | <a id="abstract"></a> `abstract` | `boolean` | | [types/index.ts:426](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L426) |
1170
- | <a id="type"></a> `type` | `string | null` | Type of a property, index signature or enum member value; null otherwise. | [types/index.ts:428](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L428) |
1171
- | <a id="summary"></a> `summary` | `string` | | [types/index.ts:429](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L429) |
1172
- | <a id="tags"></a> `tags` | `ApiTag[]` | | [types/index.ts:430](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L430) |
1173
- | <a id="signatures"></a> `signatures` | `ApiSignature[]` | Signatures of constructors, methods, accessors (get then set) and call signatures. | [types/index.ts:432](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L432) |
1174
- | <a id="source"></a> `source` | `ApiSource` | | [types/index.ts:433](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L433) |
1163
+ | <a id="name"></a> `name` | `string` | | [types/index.ts:433](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L433) |
1164
+ | <a id="kind"></a> `kind` | [`ApiMemberKind`](#apimemberkind) | | [types/index.ts:434](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L434) |
1165
+ | <a id="static"></a> `static` | `boolean` | | [types/index.ts:435](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L435) |
1166
+ | <a id="readonly"></a> `readonly` | `boolean` | | [types/index.ts:436](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L436) |
1167
+ | <a id="optional"></a> `optional` | `boolean` | | [types/index.ts:437](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L437) |
1168
+ | <a id="protected"></a> `protected` | `boolean` | | [types/index.ts:438](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L438) |
1169
+ | <a id="abstract"></a> `abstract` | `boolean` | | [types/index.ts:439](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L439) |
1170
+ | <a id="type"></a> `type` | `string \| null` | Type of a property, index signature or enum member value; null otherwise. | [types/index.ts:441](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L441) |
1171
+ | <a id="summary"></a> `summary` | `string` | | [types/index.ts:442](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L442) |
1172
+ | <a id="tags"></a> `tags` | [`ApiTag`](#apitag)`[]` | | [types/index.ts:443](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L443) |
1173
+ | <a id="signatures"></a> `signatures` | [`ApiSignature`](#apisignature)`[]` | Signatures of constructors, methods, accessors (get then set) and call signatures. | [types/index.ts:445](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L445) |
1174
+ | <a id="source"></a> `source` | [`ApiSource`](#apisource) | | [types/index.ts:446](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L446) |
1175
1175
 
1176
1176
  ***
1177
1177
 
@@ -1185,12 +1185,14 @@ type ApiLinkTarget = {
1185
1185
  name: string;
1186
1186
  kind: ApiSymbolKind;
1187
1187
  kindDir: string;
1188
+ /** Page of the target symbol (its `page`), or null when it is on the index. */
1189
+ page: string | null;
1188
1190
  /** Member part of the target (`use` in `DBModel.use`), or null. */
1189
1191
  member: string | null;
1190
1192
  };
1191
1193
  ```
1192
1194
 
1193
- Defined in: [types/index.ts:440](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L440)
1195
+ Defined in: [types/index.ts:453](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L453)
1194
1196
 
1195
1197
  A ``...`` target in a symbol's documentation that resolves to an
1196
1198
  exported symbol (or a member of one) of the same datasource.
@@ -1199,11 +1201,12 @@ exported symbol (or a member of one) of the same datasource.
1199
1201
 
1200
1202
  | Property | Type | Description | Defined in |
1201
1203
  | ------ | ------ | ------ | ------ |
1202
- | <a id="target"></a> `target` | `string` | Target as written in the comment, e.g. `DBModel.use`. | [types/index.ts:442](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L442) |
1203
- | <a id="name"></a> `name` | `string` | Exported symbol the target names. | [types/index.ts:444](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L444) |
1204
- | <a id="kind"></a> `kind` | `ApiSymbolKind` | | [types/index.ts:445](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L445) |
1205
- | <a id="kinddir"></a> `kindDir` | `string` | | [types/index.ts:446](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L446) |
1206
- | <a id="member"></a> `member` | `string | null` | Member part of the target (`use` in `DBModel.use`), or null. | [types/index.ts:448](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L448) |
1204
+ | <a id="target"></a> `target` | `string` | Target as written in the comment, e.g. `DBModel.use`. | [types/index.ts:455](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L455) |
1205
+ | <a id="name"></a> `name` | `string` | Exported symbol the target names. | [types/index.ts:457](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L457) |
1206
+ | <a id="kind"></a> `kind` | [`ApiSymbolKind`](#apisymbolkind) | | [types/index.ts:458](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L458) |
1207
+ | <a id="kinddir"></a> `kindDir` | `string` | | [types/index.ts:459](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L459) |
1208
+ | <a id="page"></a> `page` | `string \| null` | Page of the target symbol (its `page`), or null when it is on the index. | [types/index.ts:461](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L461) |
1209
+ | <a id="member"></a> `member` | `string \| null` | Member part of the target (`use` in `DBModel.use`), or null. | [types/index.ts:463](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L463) |
1207
1210
 
1208
1211
  ***
1209
1212
 
@@ -1232,14 +1235,23 @@ type ApiSymbol = {
1232
1235
  /** Members of a class, interface, enum, or object type alias. */
1233
1236
  members: ApiMember[];
1234
1237
  source: ApiSource;
1238
+ /** True for an `abstract` class. */
1239
+ abstract: boolean;
1240
+ /** Whether the symbol has a page of its own (its kind is in the datasource's `pages`). */
1241
+ hasPage: boolean;
1242
+ /** Path of its page relative to the API root (`classes/Store.md`), or null. */
1243
+ page: string | null;
1235
1244
  /** For a `reference` (`export { A as B }`): the name `A` is documented under; null otherwise. */
1236
1245
  referenceOf: string | null;
1237
- /** `{@link ...}` targets (and `referenceOf`) that resolve to exported symbols of the datasource. */
1246
+ /**
1247
+ * Exported symbols this symbol refers to: `{@link ...}` targets, `referenceOf`,
1248
+ * and names used in its types (parameters, returns, properties, heritage).
1249
+ */
1238
1250
  links: ApiLinkTarget[];
1239
1251
  };
1240
1252
  ```
1241
1253
 
1242
- Defined in: [types/index.ts:458](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L458)
1254
+ Defined in: [types/index.ts:473](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L473)
1243
1255
 
1244
1256
  One record of the `typescript` datasource: an exported symbol.
1245
1257
 
@@ -1251,22 +1263,25 @@ e.g. `./docs/api/{kindDir}/{name}.md`.
1251
1263
 
1252
1264
  | Property | Type | Description | Defined in |
1253
1265
  | ------ | ------ | ------ | ------ |
1254
- | <a id="name"></a> `name` | `string` | Exported name. | [types/index.ts:460](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L460) |
1255
- | <a id="kind"></a> `kind` | `ApiSymbolKind` | | [types/index.ts:461](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L461) |
1256
- | <a id="kindlabel"></a> `kindLabel` | `string` | Display name of the kind, e.g. `Class`, `Type Alias`. | [types/index.ts:463](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L463) |
1257
- | <a id="kinddir"></a> `kindDir` | `string` | Directory name for the kind, e.g. `classes`, `type-aliases`. | [types/index.ts:465](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L465) |
1258
- | <a id="category"></a> `category` | `string | null` | Text of the `@category` tag (also kept in `tags`), or null. | [types/index.ts:467](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L467) |
1259
- | <a id="summary"></a> `summary` | `string` | | [types/index.ts:468](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L468) |
1260
- | <a id="tags"></a> `tags` | `ApiTag[]` | | [types/index.ts:469](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L469) |
1261
- | <a id="code"></a> `code` | `string | null` | Declaration as code for type aliases and variables; null otherwise. | [types/index.ts:471](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L471) |
1262
- | <a id="typeparameters"></a> `typeParameters` | `ApiTypeParameter[]` | | [types/index.ts:472](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L472) |
1263
- | <a id="extends"></a> `extends` | `string[]` | | [types/index.ts:473](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L473) |
1264
- | <a id="implements"></a> `implements` | `string[]` | | [types/index.ts:474](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L474) |
1265
- | <a id="signatures"></a> `signatures` | `ApiSignature[]` | Overload signatures of a function. | [types/index.ts:476](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L476) |
1266
- | <a id="members"></a> `members` | `ApiMember[]` | Members of a class, interface, enum, or object type alias. | [types/index.ts:478](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L478) |
1267
- | <a id="source"></a> `source` | `ApiSource` | | [types/index.ts:479](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L479) |
1268
- | <a id="referenceof"></a> `referenceOf` | `string | null` | For a `reference` (`export { A as B }`): the name `A` is documented under; null otherwise. | [types/index.ts:481](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L481) |
1269
- | <a id="links"></a> `links` | `ApiLinkTarget[]` | ``...`` targets (and `referenceOf`) that resolve to exported symbols of the datasource. | [types/index.ts:483](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L483) |
1266
+ | <a id="name"></a> `name` | `string` | Exported name. | [types/index.ts:475](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L475) |
1267
+ | <a id="kind"></a> `kind` | [`ApiSymbolKind`](#apisymbolkind) | | [types/index.ts:476](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L476) |
1268
+ | <a id="kindlabel"></a> `kindLabel` | `string` | Display name of the kind, e.g. `Class`, `Type Alias`. | [types/index.ts:478](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L478) |
1269
+ | <a id="kinddir"></a> `kindDir` | `string` | Directory name for the kind, e.g. `classes`, `type-aliases`. | [types/index.ts:480](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L480) |
1270
+ | <a id="category"></a> `category` | `string \| null` | Text of the `@category` tag (also kept in `tags`), or null. | [types/index.ts:482](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L482) |
1271
+ | <a id="summary"></a> `summary` | `string` | | [types/index.ts:483](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L483) |
1272
+ | <a id="tags"></a> `tags` | [`ApiTag`](#apitag)`[]` | | [types/index.ts:484](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L484) |
1273
+ | <a id="code"></a> `code` | `string \| null` | Declaration as code for type aliases and variables; null otherwise. | [types/index.ts:486](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L486) |
1274
+ | <a id="typeparameters"></a> `typeParameters` | [`ApiTypeParameter`](#apitypeparameter)`[]` | | [types/index.ts:487](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L487) |
1275
+ | <a id="extends"></a> `extends` | `string[]` | | [types/index.ts:488](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L488) |
1276
+ | <a id="implements"></a> `implements` | `string[]` | | [types/index.ts:489](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L489) |
1277
+ | <a id="signatures"></a> `signatures` | [`ApiSignature`](#apisignature)`[]` | Overload signatures of a function. | [types/index.ts:491](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L491) |
1278
+ | <a id="members"></a> `members` | [`ApiMember`](#apimember)`[]` | Members of a class, interface, enum, or object type alias. | [types/index.ts:493](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L493) |
1279
+ | <a id="source"></a> `source` | [`ApiSource`](#apisource) | | [types/index.ts:494](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L494) |
1280
+ | <a id="abstract"></a> `abstract` | `boolean` | True for an `abstract` class. | [types/index.ts:496](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L496) |
1281
+ | <a id="haspage"></a> `hasPage` | `boolean` | Whether the symbol has a page of its own (its kind is in the datasource's `pages`). | [types/index.ts:498](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L498) |
1282
+ | <a id="page"></a> `page` | `string \| null` | Path of its page relative to the API root (`classes/Store.md`), or null. | [types/index.ts:500](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L500) |
1283
+ | <a id="referenceof"></a> `referenceOf` | `string \| null` | For a `reference` (`export { A as B }`): the name `A` is documented under; null otherwise. | [types/index.ts:502](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L502) |
1284
+ | <a id="links"></a> `links` | [`ApiLinkTarget`](#apilinktarget)`[]` | Exported symbols this symbol refers to: ``...`` targets, `referenceOf`, and names used in its types (parameters, returns, properties, heritage). | [types/index.ts:507](https://github.com/foo-ogawa/embedoc/blob/main/src/types/index.ts#L507) |
1270
1285
 
1271
1286
  ## Variables
1272
1287
 
@@ -1358,19 +1373,19 @@ export default defineEmbed({
1358
1373
  function renderApiIndex(records: QueryResult, options?: ApiMarkdownOptions): string;
1359
1374
  ```
1360
1375
 
1361
- Defined in: [helpers/api-markdown.ts:388](https://github.com/foo-ogawa/embedoc/blob/main/src/helpers/api-markdown.ts#L388)
1376
+ Defined in: [helpers/api-markdown.ts:448](https://github.com/foo-ogawa/embedoc/blob/main/src/helpers/api-markdown.ts#L448)
1362
1377
 
1363
1378
  Render the index page of an API: symbols grouped by kind (and by `@category`).
1364
1379
 
1365
- Symbols of `ownFileKinds` are listed as links to `<kindDir>/<name>.md`;
1380
+ Symbols with a page (the datasource's `pages`) are listed as links to it;
1366
1381
  the others are written in full. Records keep the order of the datasource.
1367
1382
 
1368
1383
  #### Parameters
1369
1384
 
1370
1385
  | Parameter | Type | Description |
1371
1386
  | ------ | ------ | ------ |
1372
- | `records` | `QueryResult` | Records of a `typescript` datasource |
1373
- | `options?` | `ApiMarkdownOptions` | Rendering options **Default** `{}` |
1387
+ | `records` | [`QueryResult`](#queryresult) | Records of a `typescript` datasource |
1388
+ | `options?` | [`ApiMarkdownOptions`](#apimarkdownoptions) | Rendering options **Default** `{}` |
1374
1389
 
1375
1390
  #### Returns
1376
1391
 
@@ -1386,16 +1401,16 @@ Markdown
1386
1401
  function renderApiPage(record: Record<string, unknown>, options?: ApiMarkdownOptions): string;
1387
1402
  ```
1388
1403
 
1389
- Defined in: [helpers/api-markdown.ts:429](https://github.com/foo-ogawa/embedoc/blob/main/src/helpers/api-markdown.ts#L429)
1404
+ Defined in: [helpers/api-markdown.ts:488](https://github.com/foo-ogawa/embedoc/blob/main/src/helpers/api-markdown.ts#L488)
1390
1405
 
1391
- Render the page of one symbol (for `<kindDir>/<name>.md`).
1406
+ Render the page of one symbol (its `page`, `<kindDir>/<name>.md`).
1392
1407
 
1393
1408
  #### Parameters
1394
1409
 
1395
1410
  | Parameter | Type | Description |
1396
1411
  | ------ | ------ | ------ |
1397
1412
  | `record` | `Record<string, unknown>` | One record of a `typescript` datasource |
1398
- | `options?` | `ApiMarkdownOptions` | Rendering options; `ownFileKinds` and `indexFile` decide the links to other symbols **Default** `{}` |
1413
+ | `options?` | [`ApiMarkdownOptions`](#apimarkdownoptions) | Rendering options; `indexFile` is used for links to symbols written on the index **Default** `{}` |
1399
1414
 
1400
1415
  #### Returns
1401
1416
 
@@ -1441,11 +1456,11 @@ export default defineDatasource({
1441
1456
 
1442
1457
  | Parameter | Type | Description |
1443
1458
  | ------ | ------ | ------ |
1444
- | `definition` | `CustomDatasourceDefinition` | The custom datasource definition |
1459
+ | `definition` | [`CustomDatasourceDefinition`](#customdatasourcedefinition) | The custom datasource definition |
1445
1460
 
1446
1461
  #### Returns
1447
1462
 
1448
- `CustomDatasourceDefinition`
1463
+ [`CustomDatasourceDefinition`](#customdatasourcedefinition)
1449
1464
 
1450
1465
  The same definition (for type inference)
1451
1466