Skip to content

Commit c979536

Browse files
committed
chore: Improve descriptions per code review
1 parent 2b28ec8 commit c979536

File tree

2 files changed

+17
-19
lines changed

2 files changed

+17
-19
lines changed

main/glossary/README.md

Lines changed: 11 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -251,12 +251,12 @@ For details, see [`E(zoe).offer(...)`](/reference/zoe-api/zoe.md#proposals).
251251
## Facet
252252

253253
A *facet* is an object that exposes an API or particular view of some larger entity, which may be an object itself.
254-
You can make any number of facets of an entity. In JavaScript, you often make a facet by selecting methods from the entity,
255-
either directly or by destructuring:
254+
You can make any number of facets of an entity. In JavaScript, you often make a facet that forwards method calls:
256255
```js
257-
const facet = {
258-
myMethod: oldObject.method,
259-
}
256+
import { Far } from '@endo/far';
257+
const facet = Far('FacetName', {
258+
myMethod: (...args) => oldObject.method(...args),
259+
});
260260
```
261261
Two Agoric uses are:
262262
- *Deposit Facet*: A facet of a [purse](#purse). Anyone with a reference to its deposit facet object can add
@@ -285,7 +285,7 @@ its [section in the JavaScript Distributed Programming Guide](https://github.com
285285
## Hardened JavaScript (SES)
286286

287287
Hardened JavaScript is a standards-track extension to the JavaScript standard.
288-
Hardening JavaScript turns the sandbox into firm ground, where you can code run
288+
Hardening JavaScript turns the sandbox into firm ground, where you can run code
289289
you don't completely trust, without being vulnerable to their bugs or bad
290290
intentions.
291291
See the [Endo and Hardened JavaScript Programming
@@ -554,13 +554,11 @@ it set at $10. They can specify the instance's minimum bid amount in its terms.
554554

555555
## Value
556556

557-
Values are the part of an [amount](#amount) that describe the value of something
558-
that can be owned or shared: How much, how many, or a description of a unique asset, such as
559-
Pixel(3,2), $3, or “Seat J12 for the show September 27th at 9:00pm”.
560-
[Fungible](#fungible) values are usually represented by natural numbers.
561-
Other values may be represented as a CopySet of strings naming particular rights or
562-
arbitrary objects representing the rights directly (usually [non-fungible](#non-fungible) assets).
563-
Values must be [Keys](#key).
557+
A value is the part of an [Amount](#amount) that describes the value of something
558+
that can be owned or shared: how much, how many, or a description of a unique asset, such as
559+
$3, Pixel(3,2), or “Seat J12 for the show September 27th at 9:00pm”.
560+
For a [fungible](#fungible) Amount, the Value is usually a non-negative **BigInt** such as `10n` or `137n`.
561+
For a [non-fungible](#non-fungible) Amount, the Value might be a [CopySet](/guides/js-programming/far.md#pass-styles-and-harden) containing strings naming particular rights or objects representing the rights directly.
564562

565563
For more information, see the [ERTP documentation's Value section](/guides/ertp/amounts.md#values).
566564

main/reference/ertp-api/ertp-data-types.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -36,12 +36,12 @@ someAmountShape: {
3636

3737
## Value
3838

39-
**Values** describe how much of something can be owned or shared.
40-
For fungible **[Amounts](#amount)**, **Values** are non-negative **BigInts**.
41-
For non-fungible **Amounts**, **Values** are [copyArrays](/guides/js-programming/far.md#passstyleof-api)
42-
(e.g., a hardened array of strings).
43-
44-
Recall that **BigInt**s are written with an *n* at the end: **10n**, **137n**, etc.
39+
A **Value** is the part of an [Amount](#amount) that describes the value of something
40+
that can be owned or shared: how much, how many, or a description of a unique asset, such as
41+
$3, Pixel(3,2), or “Seat J12 for the show September 27th at 9:00pm”.
42+
For a fungible **Amount**, the **Value** is usually a non-negative **BigInt** such as `10n` or `137n`.
43+
For a non-fungible **Amount**, the **Value** might be a [CopySet](/guides/js-programming/far.md#pass-styles-and-harden) containing strings naming particular rights or objects representing the rights directly.
44+
Values must be [Keys](/glossary/#key).
4545

4646
## AssetKind
4747

0 commit comments

Comments
 (0)