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: design/website/docs/type/readonly-object.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
@@ -1,6 +1,6 @@
1
-
# Type.ReadonlyType
1
+
# Type.ReadonlyObject
2
2
3
-
This type is an alias for the`Readonly<T>`TypeScript utility type. It makes all properties of an Object `readonly` or marks an Array or Tuple as immutable `readonly T[]`.
3
+
This type is an alias for TypeScript's`Readonly<T>` utility type. It will make all properties of a TObject readonly or marks an TArray or TTuple as immutable `readonly T[]`.
4
4
5
5
## Example
6
6
@@ -13,7 +13,7 @@ const T = Type.Object({ // const T = TObject<{
13
13
z: Type.Number() // z: TNumber,
14
14
}) // }>
15
15
16
-
const S =Type.ReadonlyType(T)// const S: TObject<{
16
+
const S =Type.ReadonlyObject(T) // const S: TObject<{
17
17
// x: TReadonly<TNumber>,
18
18
// y: TReadonly<TNumber>,
19
19
// z: TReadonly<TNumber>
@@ -28,7 +28,7 @@ const T = Type.Tuple([ // const T = TImmutable<TTup
28
28
Type.String(), // TString
29
29
]) // ]>>
30
30
31
-
const S =Type.ReadonlyType(T)// const S: TImmutable<TTuple<[
31
+
const S =Type.ReadonlyObject(T) // const S: TImmutable<TTuple<[
Copy file name to clipboardExpand all lines: docs/docs/type/readonly-object.html
+4-4Lines changed: 4 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -1,5 +1,5 @@
1
-
<h1>Type.ReadonlyType</h1>
2
-
<p>This type is an alias for the<code>Readonly<T></code>TypeScript utility type. It makes all properties of an Object <code>readonly</code> or marks an Array or Tuple as immutable <code>readonly T[]</code>.</p>
1
+
<h1>Type.ReadonlyObject</h1>
2
+
<p>This type is an alias for TypeScript's<code>Readonly<T></code> utility type. It will make all properties of a TObject readonly or marks an TArray or TTuple as immutable <code>readonly T[]</code>.</p>
3
3
<h2>Example</h2>
4
4
<p>When applied to a Object, each property of the Object will be marked as <code>TReadonly<T></code></p>
5
5
<pre><codeclass="language-typescript">const T = Type.Object({ // const T = TObject<{
@@ -8,7 +8,7 @@ <h2>Example</h2>
8
8
z: Type.Number() // z: TNumber,
9
9
}) // }>
10
10
11
-
const S = Type.ReadonlyType(T) // const S: TObject<{
11
+
const S = Type.ReadonlyObject(T) // const S: TObject<{
12
12
// x: TReadonly<TNumber>,
13
13
// y: TReadonly<TNumber>,
14
14
// z: TReadonly<TNumber>
@@ -20,7 +20,7 @@ <h2>Example</h2>
20
20
Type.String(), // TString
21
21
]) // ]>>
22
22
23
-
const S = Type.ReadonlyType(T) // const S: TImmutable<TTuple<[
23
+
const S = Type.ReadonlyObject(T) // const S: TImmutable<TTuple<[
0 commit comments