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: docs/integrations/visual_studio_code.md
+3-12Lines changed: 3 additions & 12 deletions
Original file line number
Diff line number
Diff line change
@@ -283,16 +283,7 @@ This is a limitation of dataclass transforms and cannot be fixed in pydantic.
283
283
284
284
These details are only useful for other library authors, etc.
285
285
286
-
This additional editor support works by implementing the proposed draft standard for[Dataclass Transform (PEP 681)](https://peps.python.org/pep-0681/).
286
+
This additional editor support works by making use of the[`@dataclass_transform` decorator](https://typing.python.org/en/latest/spec/dataclasses.html#the-dataclass-transform-decorator)
The proposed draft standard is written by Eric Traut, from the Microsoft team, the same author of the open source package Pyright (used by Pylance to provide Python support in VS Code).
289
-
290
-
The intention of the standard is to provide a way for libraries like Pydantic and others to tell editors and tools that they (the editors) should treat these libraries (e.g. Pydantic) as if they were`dataclasses`, providing autocompletion, type checks, etc.
291
-
292
-
The draft standard also includes an[Alternate Form](https://github.com/microsoft/pyright/blob/master/specs/dataclass_transforms.md#alternate-form) for early adopters, like Pydantic, to add support for it right away, even before the new draft standard is finished and approved.
293
-
294
-
This new draft standard, with the Alternate Form, is already supported by Pyright, so it can be used via Pylance in VS Code.
295
-
296
-
As it is being proposed as an official standard for Python, other editors can also easily add support for it.
297
-
298
-
And authors of other libraries similar to Pydantic can also easily adopt the standard right away (using the "Alternate Form") and get the benefits of these additional editor features.
289
+
The standard provides a way for libraries like Pydantic and others to tell editors and tools that they (the editors) should treat these libraries (e.g. Pydantic) as if they were[dataclasses][dataclasses], providing autocompletion, type checks, etc.