Generate DARE TypeScript resources from Pydantic Ex models.
Project description
exdrf-gen-pd2dare
exdrf-gen-pd2dare is an exdrf-gen plugin that emits DARE
TypeScript resources (*.ts), per-category index.ts, and root
dataset.ts from Pydantic ExModel subclasses (names ending in Ex).
Use the pd2dare command once exdrf_pd models are importable (see
environment variables below).
The PyPI distribution name is exdrf-gen-pd2dare; the import package is
exdrf_gen_pd2dare.
Installation
Install exdrf-gen plus this plugin (and their stacks):
pip install exdrf-gen-pd2dare
Editable monorepo install:
pip install -e ./exdrf-gen-pd2dare
Command-line interface
After installation, exdrf-gen --help lists pd2dare.
exdrf-gen pd2dare /path/to/out
Or:
python -m exdrf_gen pd2dare /path/to/out
The output directory must exist (create it in your Makefile or shell script).
Environment variables
EXDRF_PYDANTIC_MODELS_MODULES: comma-separated module names to import before building the dataset (seeexdrf_pd.model_import). If unset,RESI_PYDANTIC_MODELS_MODULESis used as a deprecated fallback.EXDRF_PD2DARE_PATH: default output directory when the path argument is omitted.
Templates
Jinja templates live under exdrf_gen_pd2dare/pd2dare_templates/ and are
registered via install_plugin.
Related packages
exdrf-gen— shared CLI and Jinja environment.exdrf-pd— Pydantic loaders anddataset_from_pydantic.exdrf-ts— field / Python type to TypeScript mapping.
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_gen_pd2dare-0.1.18.tar.gz.
File metadata
- Download URL: exdrf_gen_pd2dare-0.1.18.tar.gz
- Upload date:
- Size: 8.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
b553e88b454d01ed5f7051f1eee6ebc84cd6e7f04c819fc795f6b049a274c0df
|
|
| MD5 |
8a75fd842121363c61a2fcec81faaec4
|
|
| BLAKE2b-256 |
1565e52c655c893133f70f619f82df15e082217fe69f8699dac0d0df686fb389
|
File details
Details for the file exdrf_gen_pd2dare-0.1.18-py3-none-any.whl.
File metadata
- Download URL: exdrf_gen_pd2dare-0.1.18-py3-none-any.whl
- Upload date:
- Size: 10.0 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 |
6e5c240cabc7a1e8f72f95e64262cceaa1bba02dfbe2cf583cc4e7da96c1a133
|
|
| MD5 |
f8fae09f4c7ec07e1d24933c436964c9
|
|
| BLAKE2b-256 |
7ace5f88c2e3e38fab148e327a0a26248852dc8c9f2af55a80d7ee58adbf9dae
|