Skip to content

Commit

Permalink
Merge pull request #863 from yytypescript/feature/862
Browse files Browse the repository at this point in the history
docs: ✏️ コードブロックが表示されなくなっていたのを修正しました
  • Loading branch information
jamashita committed Apr 26, 2024
2 parents 5913863 + 79b2a4b commit 56bac13
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion docs/reference/type-reuse/union-distribution.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,10 @@ type Wrapper<T> = {
type Wrapper<T> = {
value: T;
};

// ---cut---
type IntOrStr = Wrapper<number | string>;
// ^?
// ^?
```

予想通りの結果が出ますが、実はこれはユニオン分配によって`Wrapper<number> | Wrapper<string>`として評価されたあとの結果を示しています。
Expand Down

0 comments on commit 56bac13

Please sign in to comment.