{"id":16529302,"url":"https://github.com/cometkim/mattergen","last_synced_at":"2026-05-12T15:31:21.935Z","repository":{"id":98896258,"uuid":"124534862","full_name":"cometkim/mattergen","owner":"cometkim","description":"WIP: Automatically generates type definitions from Mattermost core","archived":false,"fork":false,"pushed_at":"2018-03-29T14:02:08.000Z","size":42,"stargazers_count":1,"open_issues_count":1,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-20T18:34:14.662Z","etag":null,"topics":["codegen","flow","mattermost","typescript"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cometkim.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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}},"created_at":"2018-03-09T11:58:46.000Z","updated_at":"2025-01-16T12:50:52.000Z","dependencies_parsed_at":null,"dependency_job_id":"ea82e3f6-1523-4236-af27-2ecbeeaff03c","html_url":"https://github.com/cometkim/mattergen","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/cometkim/mattergen","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cometkim%2Fmattergen","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cometkim%2Fmattergen/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cometkim%2Fmattergen/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cometkim%2Fmattergen/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cometkim","download_url":"https://codeload.github.com/cometkim/mattergen/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cometkim%2Fmattergen/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32945253,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-12T09:19:52.626Z","status":"ssl_error","status_checked_at":"2026-05-12T09:17:33.438Z","response_time":102,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["codegen","flow","mattermost","typescript"],"created_at":"2024-10-11T17:44:25.617Z","updated_at":"2026-05-12T15:31:21.917Z","avatar_url":"https://github.com/cometkim.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"🚧 Work In Progress 🚧\n\nRoadmap discussion is open!: https://github.com/cometkim/mattermost-typegen/issues/1\n\n# mattermost-typegen\nAutomatically generates type definitions from Mattermost core\n\n## Why\nMattermost core is already typed by Go, but not in JS clients and integrations.\n\nBefore Mattermost client started using flow, I had started 3rd-party flow type library as [mattermost-typed](https://github.com/cometkim/mattermost-typed) to support types also in clients and integrations, but there are some problems I met:\n\n- mattermost-redux mostly targets on browsers, but it's not fit in server-like integrations (at least I felt).\n- It's hard to keep a huge amount of type definitions **up-to-date**.\n- Flow is effective for functional programming like redux codebase. However, community support is much better with TypeScript.\n- Have to **do all this again**, If someone need types in different ways like TypeScript, GraphQL, etc.\n\n## How this works\n\n1. Parses [Go AST](https://golang.org/pkg/go/ast/) from [mattermost-server/model](https://github.com/mattermost/mattermost-server/tree/master/model)\n2. Imports only struct type declarations and json-tagged fields.\n3. Converts to valid types for a target. for example in TypeScript, `int` in Go should be `number` in TypeScript\n4. Generates type definition files using [Go template](https://golang.org/pkg/text/template/)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcometkim%2Fmattergen","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcometkim%2Fmattergen","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcometkim%2Fmattergen/lists"}