You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: exercises/concept/appointment-time/.docs/introduction.md
+4-4Lines changed: 4 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -27,7 +27,7 @@ const now = new Date();
27
27
// Shows current day, date and time (in your time zone).
28
28
```
29
29
30
-
### Unix timestamp (number)
30
+
### **Unix timestamp (number)**
31
31
32
32
If a number is passed in, this will be interpreted as a `timestamp`.
33
33
A timestamp is an integer number representing the number of **milliseconds** that has passed since **1 January 1970 [UTC][defn-utc]+0**.
@@ -42,7 +42,7 @@ const another = new Date(1749508766627);
42
42
43
43
One may expect `new Date(0)` to generate the "earliest" date object, but JavaScript will convert the date to your local timezone, which means that only those around [GMT / with an UTC+0][defn-gmt] timezone will actually get the [Unix epoch][defn-unix-epoch] value.
44
44
45
-
### ISO 8601 timestamp (string)
45
+
### **ISO 8601 timestamp (string)**
46
46
47
47
You can pass a string value representing a date to the `Date` constructor.
48
48
The **only** format that is consistent across implementations is the [simplified version][mdn-date-string-format] of the internationally recognized and standardized so-called [ISO 8601 timestamp strings][defn-iso8601].
@@ -85,7 +85,7 @@ If the timestamp does not end in `Z`, and it does not end with `+HH:MM` or `-HH:
85
85
> The interpretation as a UTC time is due to a historical spec error that was not consistent with ISO 8601 but could not be changed due to web compatibility.
86
86
> See [Broken Parser – A Web Reality Issue][ref-broken-parser].
87
87
88
-
### Date object
88
+
### **Date object**
89
89
90
90
An existing date object can also be used as a constructor argument.
91
91
This makes a copy of the existing `Date` object with the same date and time.
@@ -96,7 +96,7 @@ const t2 = new Date(t1);
96
96
// Values of t1 and t2 will be the same.
97
97
```
98
98
99
-
### Supplying individual date and time component values
99
+
### **Supplying individual date and time component values**
100
100
101
101
A date representing a date can be created by passing three numbers.
102
102
A date representing a date and time can be created by passing in 6 numbers.
0 commit comments