mirror of
https://github.com/microsoft/pyright.git
synced 2024-08-16 19:30:26 +03:00
Update dataclass_transforms.md (#2820)
Fix typo in example code for field definition.
This commit is contained in:
parent
4fe3f1f7c0
commit
597ccabd07
@ -329,7 +329,7 @@ def create_model(
|
|||||||
# Code that imports this library:
|
# Code that imports this library:
|
||||||
@create_model(init=False)
|
@create_model(init=False)
|
||||||
class CustomerModel:
|
class CustomerModel:
|
||||||
id: int = ModelField(resolver=lambda : 0)
|
id: int = model_field(resolver=lambda : 0)
|
||||||
name: str
|
name: str
|
||||||
```
|
```
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user