Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expand string parsing/formatting documentation, including a new FAQ #2059

Merged
merged 1 commit into from
Feb 16, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 5 additions & 8 deletions docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -233,24 +233,21 @@ date.daysInYear; // => 365

See [Temporal.Calendar Documentation](./calendar.md) for detailed documentation.

## Object Relationship
## Object relationship

<img src="object-model.svg">

## String Persistence
## String persistence, parsing, and formatting

All `Temporal` types have a string representation for persistence and interoperability.
The correspondence between types and strings is shown below.
For more information about extensions to the ISO 8601 / RFC 3339 standards that are used by Temporal and which are intended to be put on a standards track, see [ISO string extensions](./iso-string-ext.md).
The correspondence between types and machine-readable strings is shown below.
For more information about string parsing, serialization, and formatting in `Temporal` (including how Temporal is using industry standards like ISO 8601 and RFC 3339), see [String Parsing, Serialization, and Formatting](./strings.md).

<img src="persistence-model.svg">

## Other Documentation

### **Key Concepts**
## Other documentation

- [Ambiguity](./ambiguity.md) &mdash; Explanation of missing times and double times due to daylight saving and time zone changes.
- [Balancing](./balancing.md) &mdash; Explanation of when `Temporal.Duration` units wrap around to 0 and when they don't.
- [ISO String Extensions](./iso-string-ext.md) &mdash; Discussion of extensions to the ISO 8601 and/or RFC 3339 standards which are used by `Temporal`.
- [Why do Temporal instances have a Calendar?](./calendar-review.md) &mdash; Background about why types like `Temporal.PlainDate` or `Temporal.PlainDate` contain a calendar.
These extensions are being actively worked on with IETF to get them on a standards track.
111 changes: 0 additions & 111 deletions docs/iso-string-ext.md

This file was deleted.

5 changes: 2 additions & 3 deletions docs/ja/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ const zonedDateTime = Temporal.ZonedDateTime.from({
}); // => 1995-12-07T03:24:30.0000035-08:00[America/Los_Angeles]
```

これは Tempral において最も多くの情報を持つタイプであり、`Temporal.TimeZone`、`Temporal.Instant`、`Temporal.PlainDateTime`(これには `Temporal.Calendar` が含まれます)の組み合わせとしてみなせます。
これは Temporal において最も多くの情報を持つタイプであり、`Temporal.TimeZone`、`Temporal.Instant`、`Temporal.PlainDateTime`(これには `Temporal.Calendar` が含まれます)の組み合わせとしてみなせます。

より詳しくは[Temporal.ZonedDateTime Documentation](../zoneddatetime.md)を参照してください。

Expand Down Expand Up @@ -224,7 +224,7 @@ date.daysInYear; // => 365

## 文字列による永続性

すべての`Temporal`タイプは、永続性や相互運用性のために文字列による表現を持っています。各タイプと文字列表現の対応を以下に示します。Temporal で使用されている ISO 8601 や RFC 3339 に関する、より詳細な情報と標準化に向けた取り組みに関しては[ECMAScript 拡張の ISO-8601 と RFC 3339](./iso-string-ext.md)を参照してください。
すべての`Temporal`タイプは、永続性や相互運用性のために文字列による表現を持っています。各タイプと文字列表現の対応を以下に示します。Temporal で使用されている ISO 8601 や RFC 3339 に関する、より詳細な情報と標準化に向けた取り組みに関しては[ECMAScript 拡張の ISO-8601 と RFC 3339](./strings.md)を参照してください。

<img src="../persistence-model.svg">

Expand All @@ -234,5 +234,4 @@ date.daysInYear; // => 365

- [曖昧性](./ambiguity.md) &mdash; 時間に関する情報が欠落して曖昧さを引き起こす仕組み、2 つのタイプの時間オブジェクトが必要な理由、サマータイムやタイムゾーンの定義変更による影響
- [バランシング](./balancing.md) &mdash; `Temporal.Duration`の単位が、いつ繰り上げされる(またはされない)のかについての説明
- [ISO 文字列の拡張](./iso-string-ext.md) &mdash; `Temporal`で使用されている ISO 8601 および RFC 3339 の拡張に関する議論、IETF と連携した標準化への取り組み
- [なぜ Temporal インスタンスはカレンダーの情報を持っているのか?](./calendar-review.md) &mdash; `Temporal.PlainDate`や`Temporal.PlainDate`がカレンダーシステムを保持している理由と背景
2 changes: 1 addition & 1 deletion docs/persistence-model.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion docs/plaindate.md
Original file line number Diff line number Diff line change
Expand Up @@ -631,7 +631,7 @@ The string can be passed to `Temporal.PlainDate.from()` to create a new `Tempora

Normally, a calendar annotation is shown when `date`'s calendar is not the ISO 8601 calendar.
By setting the `calendarName` option to `'always'` or `'never'` this can be overridden to always or never show the annotation, respectively.
For more information on the calendar annotation, see [ISO string extensions](./iso-string-ext.md#calendar-systems).
For more information on the calendar annotation, see [the `Temporal` string formats documentation](./strings.md#calendar-systems).

Example usage:

Expand Down
2 changes: 1 addition & 1 deletion docs/plaindatetime.md
Original file line number Diff line number Diff line change
Expand Up @@ -875,7 +875,7 @@ Note that rounding may change the value of other units as well.

Normally, a calendar annotation is shown when `datetime`'s calendar is not the ISO 8601 calendar.
By setting the `calendarName` option to `'always'` or `'never'` this can be overridden to always or never show the annotation, respectively.
For more information on the calendar annotation, see [ISO string extensions](./iso-string-ext.md#calendar-systems).
For more information on the calendar annotation, see [the `Temporal` string formats documentation](./strings.md#calendar-systems).

Example usage:

Expand Down
2 changes: 1 addition & 1 deletion docs/plainmonthday.md
Original file line number Diff line number Diff line change
Expand Up @@ -257,7 +257,7 @@ The string can be passed to `Temporal.PlainMonthDay.from()` to create a new `Tem

Normally, a calendar annotation is shown when `monthDay`'s calendar is not the ISO 8601 calendar.
By setting the `calendarName` option to `'always'` or `'never'` this can be overridden to always or never show the annotation, respectively.
For more information on the calendar annotation, see [ISO string extensions](./iso-string-ext.md#calendar-systems).
For more information on the calendar annotation, see [the `Temporal` string formats documentation](./strings.md#calendar-systems).

Example usage:

Expand Down
2 changes: 1 addition & 1 deletion docs/plainyearmonth.md
Original file line number Diff line number Diff line change
Expand Up @@ -517,7 +517,7 @@ The string can be passed to `Temporal.PlainYearMonth.from()` to create a new `Te

Normally, a calendar annotation is shown when `yearMonth`'s calendar is not the ISO 8601 calendar.
By setting the `calendarName` option to `'always'` or `'never'` this can be overridden to always or never show the annotation, respectively.
For more information on the calendar annotation, see [ISO string extensions](./iso-string-ext.md#calendar-systems).
For more information on the calendar annotation, see [the `Temporal` string formats documentation](./strings.md#calendar-systems).

Example usage:

Expand Down
Loading