CouncilDataProject / CouncilDataProject/cdp-backend

Dynamically Generate TypeScript DB Models, Transcript Model, and other Constants

Open
#167 15 comments 1 reaction 0 assignees View on GitHub
enhancement good first issue help wanted infrastructure
Dominant language
Python
Stars
25
Forks
28
PR merge metrics
No merged PRs in 30d

Description

## Idea / Feature

Dynamically generate TypeScript object definitions from `cdp-backend` Python DB models.

## Use Case / User Story

As a developer I want to be able to add, remove, or update a database model in a single location rather than multiple.

## Solution

Add a script to `cdp-backend` that when ran will generate a TypeScript package of the database models + extras that we can push to npm on new version push.

## Alternatives

## Stakeholders

Backend maintainers
Frontend maintainers

## Major Components

* [ ] Database models TypeScript generation
* [ ] Transcript File Model TypeScript generation
* [ ] Database "ModelField" Python and TypeScript generation
* [ ] Database constants TypeScript generation
* [ ] script added as bin script to `cdp-backend`
* [ ] task added to CI building and testing that attempts to generate these models on PR push / main build
* [ ] task added to CI main building / publish job that pushes the generated TypeScript package dir to npm

## Dependencies

## Other Notes

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.