Map exdrf field and Python types to TypeScript for codegen.
Project description
exdrf-ts
exdrf-ts maps exdrf field-type constants and Python typing objects to TypeScript strings and DARE field class names. Code generators (exdrf-gen-pd2dare, exdrf-gen-openapi2rtk, app-specific pipelines) import it when emitting TS from Pydantic-backed or OpenAPI-backed resources.
The PyPI distribution name is exdrf-ts. The import package is
exdrf_ts.
Python 3.12.2+ is required. Runtime dependencies: exdrf and exdrf-pd.
Installation
pip install exdrf-ts
Editable install from the exdrf monorepo root (with other packages present as needed):
pip install -e ./exdrf-ts
API
py_type_to_ts: Python annotation or runtime type to TS type string.type_to_field_class: Maps exdrfFIELD_TYPE_*values to DARE field class names (for exampleStringField).model_rel_import: Relative import path between two models (viaexdrf_pd.visitor.ExModelVisitor).
Role in the stack
exdrf: core dataset / field model.exdrf-pd: PydanticExModeland visitors.exdrf-ts: TypeScript-oriented views of those types.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file exdrf_ts-0.1.17.tar.gz.
File metadata
- Download URL: exdrf_ts-0.1.17.tar.gz
- Upload date:
- Size: 8.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
be76fc5fbd7c2696035b710b62311f54ae036eecd844db10b9c9397a8c322360
|
|
| MD5 |
92f6bfa63ed89439995c9f13fe8fe276
|
|
| BLAKE2b-256 |
96c7d7f68ee9600be0454e884fec2f78d3f33d93d0c8bbc51d840567542514b9
|
File details
Details for the file exdrf_ts-0.1.17-py3-none-any.whl.
File metadata
- Download URL: exdrf_ts-0.1.17-py3-none-any.whl
- Upload date:
- Size: 8.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f11b2fdb07bc47d9fa689a8c90d5803197f1a4fb8d14aad253f6f2a562004bed
|
|
| MD5 |
5f1592cadb8ed769499626f1b6168bdf
|
|
| BLAKE2b-256 |
855ae5c0147911584854224006bd20747ec91a07f1f0784044b95fbfe9f8c62b
|