{"id":20340887,"url":"https://github.com/leancodepl/contractsgenerator-typescript","last_synced_at":"2025-04-11T23:24:32.053Z","repository":{"id":37970699,"uuid":"433772342","full_name":"leancodepl/contractsgenerator-typescript","owner":"leancodepl","description":null,"archived":false,"fork":false,"pushed_at":"2024-12-19T16:40:36.000Z","size":1574,"stargazers_count":1,"open_issues_count":1,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-03-23T18:53:10.594Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/leancodepl.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-12-01T09:59:29.000Z","updated_at":"2024-12-19T16:40:38.000Z","dependencies_parsed_at":"2023-12-07T09:33:13.196Z","dependency_job_id":"ef67e2c5-b3cb-4ea9-92c2-49481b43d17a","html_url":"https://github.com/leancodepl/contractsgenerator-typescript","commit_stats":{"total_commits":17,"total_committers":3,"mean_commits":5.666666666666667,"dds":0.2941176470588235,"last_synced_commit":"8a9a1868096300ceedefc29a4f08c9e30d0bc001"},"previous_names":[],"tags_count":17,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leancodepl%2Fcontractsgenerator-typescript","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leancodepl%2Fcontractsgenerator-typescript/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leancodepl%2Fcontractsgenerator-typescript/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leancodepl%2Fcontractsgenerator-typescript/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/leancodepl","download_url":"https://codeload.github.com/leancodepl/contractsgenerator-typescript/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248493748,"owners_count":21113310,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-14T21:24:31.991Z","updated_at":"2025-04-11T23:24:32.034Z","avatar_url":"https://github.com/leancodepl.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# LeanCode TypeScript Contracts Generator\n\n## Packages\n\n- [Contracts Generator](packages/generator) - utility for generating contracts/client/schema from backend contracts\n- [Admin App Generator](packages/api-admin/) - package for generating strongly typed components from generated schema\n  and client\n\n## Available plugins\n\n- [contracts](plugins/contracts/) - type generation\n- [client](plugins/client/) - api factory generation; requires `contracts` to also be used\n- [raw](plugins/raw) - prepend/append text to generated file;\n- [admin](plugins/admin) - api components schema generation; used by [Admin App Generator](packages/api-admin/)\n\n## Development\n\n### Local publish\n\nTo test your changes to the codebase you can publish all packages to local registry\n([Verdaccio](https://verdaccio.org/)) and then pull those packages to your project. To start local registry run\n\n```\nnpx nx run local-registry\n```\n\nthis will override your default registry in npm config. To publish all packages to local registry run\n\n```\nnpx nx run local-publish --ver={VERSION_IN_#.#.#_OR_#.#.#-PREFIX.#} --tag={TAG}\n```\n\n### Protobuf\n\nServer and clients communicate using protobuf. Specific `.proto` contract file is being copied from the server\nrepository to [`libs/schema/src/lib/protocol/contracts.proto`](libs/schema/src/lib/protocol/contracts.proto). This is\nimportant to note that when contracts file is updated on the backend side then updating process is entirely manual.\nAfter you copy new `contracts.proto` file the\n[`libs/schema/src/lib/protocol/index.js`](libs/schema/src/lib/protocol/index.js) and\n[`libs/schema/src/lib/protocol/index.d.ts`](libs/schema/src/lib/protocol/index.d.ts) need to be updated. Those files are\nautomatically generated by running `npx nx run schema:proto`.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fleancodepl%2Fcontractsgenerator-typescript","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fleancodepl%2Fcontractsgenerator-typescript","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fleancodepl%2Fcontractsgenerator-typescript/lists"}