Better formatting for dataverse' docs
This commit is contained in:
parent
c8430050a8
commit
6ac3b74309
9 changed files with 75 additions and 365 deletions
|
@ -22,17 +22,11 @@ Wraps an object whose (sub)properties can be individually tracked.
|
|||
|
||||
### Properties
|
||||
|
||||
- [\_currentState](Atom.md#_currentstate)
|
||||
- [\_rootScope](Atom.md#_rootscope)
|
||||
- [pointer](Atom.md#pointer)
|
||||
- [prism](Atom.md#prism)
|
||||
|
||||
### Methods
|
||||
|
||||
- [\_checkUpdates](Atom.md#_checkupdates)
|
||||
- [\_getIn](Atom.md#_getin)
|
||||
- [\_getOrCreateScopeForPath](Atom.md#_getorcreatescopeforpath)
|
||||
- [\_onPointerValueChange](Atom.md#_onpointervaluechange)
|
||||
- [get](Atom.md#get)
|
||||
- [getByPointer](Atom.md#getbypointer)
|
||||
- [pointerToPrism](Atom.md#pointertoprism)
|
||||
|
@ -61,43 +55,19 @@ Wraps an object whose (sub)properties can be individually tracked.
|
|||
|
||||
#### Defined in
|
||||
|
||||
[Atom.ts:119](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Atom.ts#L119)
|
||||
[Atom.ts:119](https://github.com/theatre-js/theatre/blob/main/packages/dataverse/src/Atom.ts#L119)
|
||||
|
||||
## Properties
|
||||
|
||||
### \_currentState
|
||||
|
||||
• `Private` **\_currentState**: `State`
|
||||
|
||||
#### Defined in
|
||||
|
||||
[Atom.ts:101](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Atom.ts#L101)
|
||||
|
||||
___
|
||||
|
||||
### \_rootScope
|
||||
|
||||
• `Private` `Readonly` **\_rootScope**: `Scope`
|
||||
|
||||
#### Defined in
|
||||
|
||||
[Atom.ts:106](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Atom.ts#L106)
|
||||
|
||||
___
|
||||
|
||||
### pointer
|
||||
|
||||
• `Readonly` **pointer**: [`Pointer`](../README.md#pointer)<`State`\>
|
||||
|
||||
Convenience property that gives you a pointer to the root of the atom.
|
||||
|
||||
**`Remarks`**
|
||||
|
||||
Equivalent to `pointer({ root: thisAtom, path: [] })`.
|
||||
|
||||
#### Defined in
|
||||
|
||||
[Atom.ts:113](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Atom.ts#L113)
|
||||
[Atom.ts:113](https://github.com/theatre-js/theatre/blob/main/packages/dataverse/src/Atom.ts#L113)
|
||||
|
||||
___
|
||||
|
||||
|
@ -107,107 +77,10 @@ ___
|
|||
|
||||
#### Defined in
|
||||
|
||||
[Atom.ts:115](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Atom.ts#L115)
|
||||
[Atom.ts:115](https://github.com/theatre-js/theatre/blob/main/packages/dataverse/src/Atom.ts#L115)
|
||||
|
||||
## Methods
|
||||
|
||||
### \_checkUpdates
|
||||
|
||||
▸ `Private` **_checkUpdates**(`scope`, `oldState`, `newState`): `void`
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `scope` | `Scope` |
|
||||
| `oldState` | `unknown` |
|
||||
| `newState` | `unknown` |
|
||||
|
||||
#### Returns
|
||||
|
||||
`void`
|
||||
|
||||
#### Defined in
|
||||
|
||||
[Atom.ts:218](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Atom.ts#L218)
|
||||
|
||||
___
|
||||
|
||||
### \_getIn
|
||||
|
||||
▸ `Private` **_getIn**(`path`): `unknown`
|
||||
|
||||
Gets the state of the atom at `path`.
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `path` | (`string` \| `number`)[] |
|
||||
|
||||
#### Returns
|
||||
|
||||
`unknown`
|
||||
|
||||
#### Defined in
|
||||
|
||||
[Atom.ts:166](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Atom.ts#L166)
|
||||
|
||||
___
|
||||
|
||||
### \_getOrCreateScopeForPath
|
||||
|
||||
▸ `Private` **_getOrCreateScopeForPath**(`path`): `Scope`
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `path` | (`string` \| `number`)[] |
|
||||
|
||||
#### Returns
|
||||
|
||||
`Scope`
|
||||
|
||||
#### Defined in
|
||||
|
||||
[Atom.ts:240](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Atom.ts#L240)
|
||||
|
||||
___
|
||||
|
||||
### \_onPointerValueChange
|
||||
|
||||
▸ `Private` **_onPointerValueChange**<`P`\>(`pointer`, `cb`): () => `void`
|
||||
|
||||
#### Type parameters
|
||||
|
||||
| Name |
|
||||
| :------ |
|
||||
| `P` |
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `pointer` | [`Pointer`](../README.md#pointer)<`P`\> |
|
||||
| `cb` | (`v`: `P`) => `void` |
|
||||
|
||||
#### Returns
|
||||
|
||||
`fn`
|
||||
|
||||
▸ (): `void`
|
||||
|
||||
##### Returns
|
||||
|
||||
`void`
|
||||
|
||||
#### Defined in
|
||||
|
||||
[Atom.ts:248](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Atom.ts#L248)
|
||||
|
||||
___
|
||||
|
||||
### get
|
||||
|
||||
▸ **get**(): `State`
|
||||
|
@ -218,7 +91,7 @@ ___
|
|||
|
||||
#### Defined in
|
||||
|
||||
[Atom.ts:136](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Atom.ts#L136)
|
||||
[Atom.ts:136](https://github.com/theatre-js/theatre/blob/main/packages/dataverse/src/Atom.ts#L136)
|
||||
|
||||
___
|
||||
|
||||
|
@ -246,7 +119,7 @@ Returns the value at the given pointer
|
|||
|
||||
#### Defined in
|
||||
|
||||
[Atom.ts:152](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Atom.ts#L152)
|
||||
[Atom.ts:152](https://github.com/theatre-js/theatre/blob/main/packages/dataverse/src/Atom.ts#L152)
|
||||
|
||||
___
|
||||
|
||||
|
@ -278,7 +151,7 @@ Returns a new prism of the value at the provided path.
|
|||
|
||||
#### Defined in
|
||||
|
||||
[Atom.ts:271](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Atom.ts#L271)
|
||||
[Atom.ts:271](https://github.com/theatre-js/theatre/blob/main/packages/dataverse/src/Atom.ts#L271)
|
||||
|
||||
___
|
||||
|
||||
|
@ -298,7 +171,7 @@ ___
|
|||
|
||||
#### Defined in
|
||||
|
||||
[Atom.ts:170](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Atom.ts#L170)
|
||||
[Atom.ts:170](https://github.com/theatre-js/theatre/blob/main/packages/dataverse/src/Atom.ts#L170)
|
||||
|
||||
___
|
||||
|
||||
|
@ -327,7 +200,7 @@ Reduces the value at the given pointer
|
|||
|
||||
#### Defined in
|
||||
|
||||
[Atom.ts:186](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Atom.ts#L186)
|
||||
[Atom.ts:186](https://github.com/theatre-js/theatre/blob/main/packages/dataverse/src/Atom.ts#L186)
|
||||
|
||||
___
|
||||
|
||||
|
@ -349,7 +222,7 @@ Sets the state of the atom.
|
|||
|
||||
#### Defined in
|
||||
|
||||
[Atom.ts:129](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Atom.ts#L129)
|
||||
[Atom.ts:129](https://github.com/theatre-js/theatre/blob/main/packages/dataverse/src/Atom.ts#L129)
|
||||
|
||||
___
|
||||
|
||||
|
@ -378,4 +251,4 @@ Sets the value at the given pointer
|
|||
|
||||
#### Defined in
|
||||
|
||||
[Atom.ts:211](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Atom.ts#L211)
|
||||
[Atom.ts:211](https://github.com/theatre-js/theatre/blob/main/packages/dataverse/src/Atom.ts#L211)
|
||||
|
|
|
@ -4,11 +4,6 @@
|
|||
|
||||
Allows creating pointer-prisms where the pointer can be switched out.
|
||||
|
||||
**`Remarks`**
|
||||
|
||||
This allows reacting not just to value changes at a certain pointer, but changes
|
||||
to the proxied pointer too.
|
||||
|
||||
## Type parameters
|
||||
|
||||
| Name | Type |
|
||||
|
@ -27,7 +22,6 @@ to the proxied pointer too.
|
|||
|
||||
### Properties
|
||||
|
||||
- [\_currentPointerBox](PointerProxy.md#_currentpointerbox)
|
||||
- [pointer](PointerProxy.md#pointer)
|
||||
|
||||
### Methods
|
||||
|
@ -55,33 +49,19 @@ to the proxied pointer too.
|
|||
|
||||
#### Defined in
|
||||
|
||||
[PointerProxy.ts:34](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/PointerProxy.ts#L34)
|
||||
[PointerProxy.ts:34](https://github.com/theatre-js/theatre/blob/main/packages/dataverse/src/PointerProxy.ts#L34)
|
||||
|
||||
## Properties
|
||||
|
||||
### \_currentPointerBox
|
||||
|
||||
• `Private` `Readonly` **\_currentPointerBox**: [`Atom`](Atom.md)<[`Pointer`](../README.md#pointer)<`O`\>\>
|
||||
|
||||
#### Defined in
|
||||
|
||||
[PointerProxy.ts:25](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/PointerProxy.ts#L25)
|
||||
|
||||
___
|
||||
|
||||
### pointer
|
||||
|
||||
• `Readonly` **pointer**: [`Pointer`](../README.md#pointer)<`O`\>
|
||||
|
||||
Convenience pointer pointing to the root of this PointerProxy.
|
||||
|
||||
**`Remarks`**
|
||||
|
||||
Allows convenient use of [pointerToPrism](PointerProxy.md#pointertoprism) and [val](../README.md#val).
|
||||
|
||||
#### Defined in
|
||||
|
||||
[PointerProxy.ts:32](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/PointerProxy.ts#L32)
|
||||
[PointerProxy.ts:32](https://github.com/theatre-js/theatre/blob/main/packages/dataverse/src/PointerProxy.ts#L32)
|
||||
|
||||
## Methods
|
||||
|
||||
|
@ -113,7 +93,7 @@ Returns a prism of the value at the provided sub-path of the proxied pointer.
|
|||
|
||||
#### Defined in
|
||||
|
||||
[PointerProxy.ts:52](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/PointerProxy.ts#L52)
|
||||
[PointerProxy.ts:52](https://github.com/theatre-js/theatre/blob/main/packages/dataverse/src/PointerProxy.ts#L52)
|
||||
|
||||
___
|
||||
|
||||
|
@ -135,4 +115,4 @@ Sets the underlying pointer.
|
|||
|
||||
#### Defined in
|
||||
|
||||
[PointerProxy.ts:43](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/PointerProxy.ts#L43)
|
||||
[PointerProxy.ts:43](https://github.com/theatre-js/theatre/blob/main/packages/dataverse/src/PointerProxy.ts#L43)
|
||||
|
|
|
@ -14,13 +14,6 @@ external scheduling strategy, e.g. a raf.
|
|||
### Properties
|
||||
|
||||
- [\_\_ticks](Ticker.md#__ticks)
|
||||
- [\_conf](Ticker.md#_conf)
|
||||
- [\_dormant](Ticker.md#_dormant)
|
||||
- [\_numberOfDormantTicks](Ticker.md#_numberofdormantticks)
|
||||
- [\_scheduledForNextTick](Ticker.md#_scheduledfornexttick)
|
||||
- [\_scheduledForThisOrNextTick](Ticker.md#_scheduledforthisornexttick)
|
||||
- [\_ticking](Ticker.md#_ticking)
|
||||
- [\_timeAtCurrentTick](Ticker.md#_timeatcurrenttick)
|
||||
|
||||
### Accessors
|
||||
|
||||
|
@ -29,9 +22,6 @@ external scheduling strategy, e.g. a raf.
|
|||
|
||||
### Methods
|
||||
|
||||
- [\_goActive](Ticker.md#_goactive)
|
||||
- [\_goDormant](Ticker.md#_godormant)
|
||||
- [\_tick](Ticker.md#_tick)
|
||||
- [offNextTick](Ticker.md#offnexttick)
|
||||
- [offThisOrNextTick](Ticker.md#offthisornexttick)
|
||||
- [onNextTick](Ticker.md#onnexttick)
|
||||
|
@ -54,7 +44,7 @@ external scheduling strategy, e.g. a raf.
|
|||
|
||||
#### Defined in
|
||||
|
||||
[Ticker.ts:43](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Ticker.ts#L43)
|
||||
[Ticker.ts:43](https://github.com/theatre-js/theatre/blob/main/packages/dataverse/src/Ticker.ts#L43)
|
||||
|
||||
## Properties
|
||||
|
||||
|
@ -70,86 +60,7 @@ Consider this as experimental, and do not rely on it always being here in future
|
|||
|
||||
#### Defined in
|
||||
|
||||
[Ticker.ts:41](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Ticker.ts#L41)
|
||||
|
||||
___
|
||||
|
||||
### \_conf
|
||||
|
||||
• `Private` `Optional` **\_conf**: `Object`
|
||||
|
||||
#### Type declaration
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `onActive?` | () => `void` |
|
||||
| `onDormant?` | () => `void` |
|
||||
|
||||
#### Defined in
|
||||
|
||||
[Ticker.ts:44](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Ticker.ts#L44)
|
||||
|
||||
___
|
||||
|
||||
### \_dormant
|
||||
|
||||
• `Private` **\_dormant**: `boolean` = `true`
|
||||
|
||||
Whether the Ticker is dormant
|
||||
|
||||
#### Defined in
|
||||
|
||||
[Ticker.ts:24](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Ticker.ts#L24)
|
||||
|
||||
___
|
||||
|
||||
### \_numberOfDormantTicks
|
||||
|
||||
• `Private` **\_numberOfDormantTicks**: `number` = `0`
|
||||
|
||||
#### Defined in
|
||||
|
||||
[Ticker.ts:26](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Ticker.ts#L26)
|
||||
|
||||
___
|
||||
|
||||
### \_scheduledForNextTick
|
||||
|
||||
• `Private` **\_scheduledForNextTick**: `Set`<`ICallback`\>
|
||||
|
||||
#### Defined in
|
||||
|
||||
[Ticker.ts:17](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Ticker.ts#L17)
|
||||
|
||||
___
|
||||
|
||||
### \_scheduledForThisOrNextTick
|
||||
|
||||
• `Private` **\_scheduledForThisOrNextTick**: `Set`<`ICallback`\>
|
||||
|
||||
#### Defined in
|
||||
|
||||
[Ticker.ts:16](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Ticker.ts#L16)
|
||||
|
||||
___
|
||||
|
||||
### \_ticking
|
||||
|
||||
• `Private` **\_ticking**: `boolean` = `false`
|
||||
|
||||
#### Defined in
|
||||
|
||||
[Ticker.ts:19](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Ticker.ts#L19)
|
||||
|
||||
___
|
||||
|
||||
### \_timeAtCurrentTick
|
||||
|
||||
• `Private` **\_timeAtCurrentTick**: `number`
|
||||
|
||||
#### Defined in
|
||||
|
||||
[Ticker.ts:18](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Ticker.ts#L18)
|
||||
[Ticker.ts:41](https://github.com/theatre-js/theatre/blob/main/packages/dataverse/src/Ticker.ts#L41)
|
||||
|
||||
## Accessors
|
||||
|
||||
|
@ -165,7 +76,7 @@ Whether the Ticker is dormant
|
|||
|
||||
#### Defined in
|
||||
|
||||
[Ticker.ts:31](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Ticker.ts#L31)
|
||||
[Ticker.ts:31](https://github.com/theatre-js/theatre/blob/main/packages/dataverse/src/Ticker.ts#L31)
|
||||
|
||||
___
|
||||
|
||||
|
@ -182,58 +93,10 @@ The time at the start of the current tick if there is a tick in progress, otherw
|
|||
|
||||
#### Defined in
|
||||
|
||||
[Ticker.ts:122](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Ticker.ts#L122)
|
||||
[Ticker.ts:122](https://github.com/theatre-js/theatre/blob/main/packages/dataverse/src/Ticker.ts#L122)
|
||||
|
||||
## Methods
|
||||
|
||||
### \_goActive
|
||||
|
||||
▸ `Private` **_goActive**(): `void`
|
||||
|
||||
#### Returns
|
||||
|
||||
`void`
|
||||
|
||||
#### Defined in
|
||||
|
||||
[Ticker.ts:128](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Ticker.ts#L128)
|
||||
|
||||
___
|
||||
|
||||
### \_goDormant
|
||||
|
||||
▸ `Private` **_goDormant**(): `void`
|
||||
|
||||
#### Returns
|
||||
|
||||
`void`
|
||||
|
||||
#### Defined in
|
||||
|
||||
[Ticker.ts:134](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Ticker.ts#L134)
|
||||
|
||||
___
|
||||
|
||||
### \_tick
|
||||
|
||||
▸ `Private` **_tick**(`iterationNumber`): `void`
|
||||
|
||||
#### Parameters
|
||||
|
||||
| Name | Type |
|
||||
| :------ | :------ |
|
||||
| `iterationNumber` | `number` |
|
||||
|
||||
#### Returns
|
||||
|
||||
`void`
|
||||
|
||||
#### Defined in
|
||||
|
||||
[Ticker.ts:184](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Ticker.ts#L184)
|
||||
|
||||
___
|
||||
|
||||
### offNextTick
|
||||
|
||||
▸ **offNextTick**(`fn`): `void`
|
||||
|
@ -256,7 +119,7 @@ onNextTick
|
|||
|
||||
#### Defined in
|
||||
|
||||
[Ticker.ts:114](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Ticker.ts#L114)
|
||||
[Ticker.ts:114](https://github.com/theatre-js/theatre/blob/main/packages/dataverse/src/Ticker.ts#L114)
|
||||
|
||||
___
|
||||
|
||||
|
@ -282,7 +145,7 @@ onThisOrNextTick
|
|||
|
||||
#### Defined in
|
||||
|
||||
[Ticker.ts:103](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Ticker.ts#L103)
|
||||
[Ticker.ts:103](https://github.com/theatre-js/theatre/blob/main/packages/dataverse/src/Ticker.ts#L103)
|
||||
|
||||
___
|
||||
|
||||
|
@ -309,7 +172,7 @@ Registers a side effect to be called on the next tick.
|
|||
|
||||
#### Defined in
|
||||
|
||||
[Ticker.ts:89](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Ticker.ts#L89)
|
||||
[Ticker.ts:89](https://github.com/theatre-js/theatre/blob/main/packages/dataverse/src/Ticker.ts#L89)
|
||||
|
||||
___
|
||||
|
||||
|
@ -342,7 +205,7 @@ offThisOrNextTick
|
|||
|
||||
#### Defined in
|
||||
|
||||
[Ticker.ts:74](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Ticker.ts#L74)
|
||||
[Ticker.ts:74](https://github.com/theatre-js/theatre/blob/main/packages/dataverse/src/Ticker.ts#L74)
|
||||
|
||||
___
|
||||
|
||||
|
@ -369,4 +232,4 @@ Triggers a tick which starts executing the callbacks scheduled for this tick.
|
|||
|
||||
#### Defined in
|
||||
|
||||
[Ticker.ts:149](https://github.com/theatre-js/theatre/blob/327b859ed/packages/dataverse/src/Ticker.ts#L149)
|
||||
[Ticker.ts:149](https://github.com/theatre-js/theatre/blob/main/packages/dataverse/src/Ticker.ts#L149)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue