Skip to content

Commit 013530d

Browse files
committed
add movie definition
1 parent 9a33331 commit 013530d

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

source/connect/mongoclient.txt

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -276,6 +276,12 @@ The following example shows how to specify the ``Movie`` type as a type hint for
276276

277277
.. code-block:: python
278278

279+
from typing import TypedDict
280+
281+
class Movie(TypedDict):
282+
name: str
283+
year: int
284+
279285
client: MongoClient[Movie] = MongoClient()
280286

281287
Troubleshooting

0 commit comments

Comments
 (0)