{"id":16010332,"url":"https://github.com/amauryd/decodb","last_synced_at":"2026-05-01T09:31:23.030Z","repository":{"id":96529454,"uuid":"415635308","full_name":"AmauryD/decodb","owner":"AmauryD","description":"denodb using decorators","archived":false,"fork":false,"pushed_at":"2021-10-14T17:52:37.000Z","size":31,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2026-04-08T04:07:58.044Z","etag":null,"topics":["decorators","deno","denodb","orm"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","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/AmauryD.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,"publiccode":null,"codemeta":null}},"created_at":"2021-10-10T16:10:31.000Z","updated_at":"2021-10-14T17:52:40.000Z","dependencies_parsed_at":null,"dependency_job_id":"881eae73-c0c5-48d8-ad48-cc0b87464d63","html_url":"https://github.com/AmauryD/decodb","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/AmauryD/decodb","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AmauryD%2Fdecodb","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AmauryD%2Fdecodb/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AmauryD%2Fdecodb/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AmauryD%2Fdecodb/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/AmauryD","download_url":"https://codeload.github.com/AmauryD/decodb/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/AmauryD%2Fdecodb/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32492087,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-30T13:12:12.517Z","status":"online","status_checked_at":"2026-05-01T02:00:05.856Z","response_time":64,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"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":["decorators","deno","denodb","orm"],"created_at":"2024-10-08T13:05:24.964Z","updated_at":"2026-05-01T09:31:23.005Z","avatar_url":"https://github.com/AmauryD.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# DecoDB [![Lint](https://github.com/AmauryD/decoDB/actions/workflows/lint.yml/badge.svg)](https://github.com/AmauryD/decoDB/actions/workflows/lint.yml) [![Tests](https://github.com/AmauryD/decoDB/actions/workflows/tests.yml/badge.svg)](https://github.com/AmauryD/decoDB/actions/workflows/tests.yml)\n\n[DenoDB](https://github.com/eveningkid/denodb) with decorators.\n\n## Installing\n\nTODO\n\n## TODO before first release\n\n- [x] Attributes decorators\n- [x] Relationships decorators\n- [ ] Tests\n- [ ] Documentation\n\n## Documentation\n\nSee the [WIKI](https://github.com/AmauryD/decodb/wiki).\n\n## Quick start\n\n### Defining models\n\n```ts\n@Entity(\"articles\")\nexport class Article extends DenoDB.Model {\n  @PrimaryColumn({ type: DenoDB.DataTypes.INTEGER, autoIncrement: true })\n  declare public id: number;\n\n  @Column({\n    type: DenoDB.DataTypes.STRING,\n    default: \"bonjour\",\n    allowNull: true,\n    unique: true,\n  })\n  declare public name: string;\n\n  declare public static comments: () =\u003e Promise\u003cComment[]\u003e;\n}\n```\n\n```ts\n@Entity(\"comments\")\nexport class Comment extends DenoDB.Model {\n  @PrimaryColumn(DenoDB.DataTypes.INTEGER)\n  declare public id: number;\n\n  @Column({\n    type: DenoDB.DataTypes.STRING,\n  })\n  declare public content: string;\n\n  @BelongsTo(() =\u003e Article, \"comments\")\n  declare public static article: () =\u003e Promise\u003cArticle\u003e;\n}\n```\n\n### Creating connection\n\n```ts\n(async() =\u003e {\n  const connector = new DenoDB.MySQLConnector({\n    ...\n  });\n  const db = new DenoDB.Database(connector);\n\n  await setupDatabase(db, {\n    models: [Article, Comment, User],\n  });\n  ...\n})();\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Famauryd%2Fdecodb","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Famauryd%2Fdecodb","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Famauryd%2Fdecodb/lists"}