Pydantic-to-typescript

Latest version: v1.0.10

Safety actively analyzes 622275 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

1.0.10

What's Changed
* Creating a github action for pydantic-to-typescript by phillipdupuis in https://github.com/phillipdupuis/pydantic-to-typescript/pull/23
* Check whether json2ts exited without any errors before processing the generated ts file by qwyt in https://github.com/phillipdupuis/pydantic-to-typescript/pull/14
* The --json2ts-cmd option should not be validated via 'shutil.which' by phillipdupuis in https://github.com/phillipdupuis/pydantic-to-typescript/pull/26

New Contributors
* qwyt made their first contribution in https://github.com/phillipdupuis/pydantic-to-typescript/pull/14

**Full Changelog**: https://github.com/phillipdupuis/pydantic-to-typescript/compare/v1.0.9...v1.0.10

1.0.9

What's Changed

* Added tests for exception raising
* Removed click dependency, since the built-in argparse module is sufficient
* Added basic action to github marketplace

1.0.7

Primary changes:
- added the option to `exclude` pydantic models from the generated typescript definitions. This is done by providing the names of the models which should be excluded. For CLI users, this can be accomplished via the `--exclude` option, ex: `--exclude MyCustomBaseModel` to exclude the model named MyCustomBaseModel from the results. And if you want to exclude multiple models, provide multiple options, ex: `--exclude Foo --exclude Bar` to exclude both Foo and Bar. For python users, this same behavior can be accomplished by passing a tuple of model names as the `exclude` kwarg to `generate_typescript_defs`.

Additional changes:
- fixed tests (even though they aren't part of CI currently) to reflect the new comment format, including the `eslint-disable` directive.
- fixed a bug in which pydantic2ts forced python progams to start logging at the DEBUG level. Logging at the DEBUG level will now only occur if pydantic2ts is invoked via the CLI. If it is called from within another python program, it will use whatever logging configuration has already been set up.

1.0.6

Links

Releases

Has known vulnerabilities

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.