Skip to content

Commit 3f904c3

Browse files
authored
📝 Updated the docs to note the Union[X, None] and X | None support (#10)
1 parent 9eddc04 commit 3f904c3

2 files changed

Lines changed: 9 additions & 3 deletions

File tree

‎README.md‎

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,8 +78,11 @@ After installing you can run auto-optional using `auto-optional [path]` (path is
7878

7979
### Things that are handled well
8080

81+
- The alternatives to `Optional` are supported, that means both;
82+
- `Union[X, None]`
83+
- `x | None` (allowed since python 10+).
8184
- Existing imports are reused.
82-
- `import as` statements are properly handled.
85+
- `import as` and `from typing import ...` statements are properly handled.
8386

8487
### Things that need improvement
8588
For all these points you can leave a thumbs-up if you want it. Also, I welcome pull-requests for these issues.

‎docs/index.md‎

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Auto-optional
2-
<img src="https://raw.githubusercontent.com/Luttik/auto-optional/main/docs/assets/images/logo-with-text.svg" style="width: 100%; margin: 32pt 0" alt="Logo">
2+
<img src="/assets/images/logo-with-text.svg" style="width: 100%; margin: 32pt 0" alt="Logo">
33

44

55
<p align="center">
@@ -78,8 +78,11 @@ After installing you can run auto-optional using `auto-optional [path]` (path is
7878

7979
### Things that are handled well
8080

81+
- The alternatives to `Optional` are supported, that means both;
82+
- `Union[X, None]`
83+
- `x | None` (allowed since python 10+).
8184
- Existing imports are reused.
82-
- `import as` statements are properly handled.
85+
- `import as` and `from typing import ...` statements are properly handled.
8386

8487
### Things that need improvement
8588
For all these points you can leave a thumbs-up if you want it. Also, I welcome pull-requests for these issues.

0 commit comments

Comments
 (0)