{"id":19911008,"url":"https://github.com/leaningtech/ts2cpp","last_synced_at":"2025-05-03T03:30:55.912Z","repository":{"id":205750945,"uuid":"713909569","full_name":"leaningtech/ts2cpp","owner":"leaningtech","description":"A tool to generate C++ headers from TypeScript declaration files","archived":false,"fork":false,"pushed_at":"2024-09-02T14:04:12.000Z","size":543,"stargazers_count":7,"open_issues_count":0,"forks_count":3,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-04-25T03:18:07.937Z","etag":null,"topics":["cheerp","cpp","typescript","typescript-definitions","wasm","webassembly"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","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/leaningtech.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-11-03T13:51:34.000Z","updated_at":"2025-03-18T03:41:49.000Z","dependencies_parsed_at":"2024-02-14T15:29:20.919Z","dependency_job_id":"bd67b677-b80d-4b68-8f10-750b64315254","html_url":"https://github.com/leaningtech/ts2cpp","commit_stats":null,"previous_names":["leaningtech/ts2cpp"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leaningtech%2Fts2cpp","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leaningtech%2Fts2cpp/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leaningtech%2Fts2cpp/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leaningtech%2Fts2cpp/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/leaningtech","download_url":"https://codeload.github.com/leaningtech/ts2cpp/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":252137517,"owners_count":21700228,"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":["cheerp","cpp","typescript","typescript-definitions","wasm","webassembly"],"created_at":"2024-11-12T21:22:58.347Z","updated_at":"2025-05-03T03:30:55.565Z","avatar_url":"https://github.com/leaningtech.png","language":"TypeScript","readme":"![ts2cpp banner](banner.png)\n\nA tool to generate C++ headers from typescript declaration files (.d.ts) for use with [Cheerp](https://github.com/leaningtech/cheerp-meta).\n\n```\nUsage: ts2cpp [options]\n\nOptions:\n  --pretty                 format output files\n  --default-lib            generate headers for the default library\n  --out, -o \u003cfile\u003e         path to output file\n  --ignore-errors          ignore errors\n  --list-files             write a list of all included .d.ts files\n  --verbose, -v            verbose output\n  --verbose-progress       verbose progress\n  --namespace \u003cnamespace\u003e  wrap output in a namespace\n  --no-constraints         do not use std::enable_if or static_asserts\n  --full-names             always use fully qualified names\n  -h, --help               display help for command\n```\n\n## Setup\n\n```\ngit clone https://github.com/leaningtech/ts2cpp.git\ncd ts2cpp\nnpm i \u0026\u0026 npx tsc\n```\n\nOr run with `npx`:\n\n```\nnpx @leaningtech/ts2cpp --help\n```\n\n## Examples\n\nGenerating clientlib headers\n\n```\nmkdir -p cheerp\nnpx ts2cpp --default-lib --pretty\n```\n\nGenerating headers from a custom declaration file\n\n```\nnpx ts2cpp --pretty test.d.ts -o test.h\n```\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fleaningtech%2Fts2cpp","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fleaningtech%2Fts2cpp","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fleaningtech%2Fts2cpp/lists"}