pydantic-to-typescript icon indicating copy to clipboard operation
pydantic-to-typescript copied to clipboard

Update for pydantic 2

Open eg-novelt opened this issue 2 years ago • 2 comments

Pydantic 2.0 just came out. This PR uses their new syntax.

One difference is that Optional parameters now output property: | null instead of property?.

All the tests passed locally.

eg-novelt avatar Jul 05 '23 13:07 eg-novelt

What's the difference between this PR and https://github.com/phillipdupuis/pydantic-to-typescript/pull/40 or https://github.com/phillipdupuis/pydantic-to-typescript/pull/38 ?

Can they be consolidated?

voidus avatar Jan 12 '24 08:01 voidus