{"id":20567355,"url":"https://github.com/sombriks/sample-htmx-chi","last_synced_at":"2026-05-15T12:08:22.662Z","repository":{"id":230409847,"uuid":"779237531","full_name":"sombriks/sample-htmx-chi","owner":"sombriks","description":"sample project demonstrating htmx on go ecosystem","archived":false,"fork":false,"pushed_at":"2024-05-04T14:32:03.000Z","size":30,"stargazers_count":1,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-08-31T16:42:44.564Z","etag":null,"topics":["go-chi","golang","gorm","htmx","liquid","liquid-templating-engine","sqlite3","study-project"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sombriks.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"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":"2024-03-29T11:03:23.000Z","updated_at":"2025-02-06T18:05:10.000Z","dependencies_parsed_at":"2024-03-29T15:25:21.134Z","dependency_job_id":"32594f9f-8636-4675-9304-f2c90c17f710","html_url":"https://github.com/sombriks/sample-htmx-chi","commit_stats":null,"previous_names":["sombriks/sample-htmx-chi"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/sombriks/sample-htmx-chi","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sombriks%2Fsample-htmx-chi","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sombriks%2Fsample-htmx-chi/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sombriks%2Fsample-htmx-chi/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sombriks%2Fsample-htmx-chi/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sombriks","download_url":"https://codeload.github.com/sombriks/sample-htmx-chi/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sombriks%2Fsample-htmx-chi/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33066184,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-15T11:35:32.926Z","status":"ssl_error","status_checked_at":"2026-05-15T11:35:31.362Z","response_time":103,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5: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":["go-chi","golang","gorm","htmx","liquid","liquid-templating-engine","sqlite3","study-project"],"created_at":"2024-11-16T04:46:27.606Z","updated_at":"2026-05-15T12:08:22.647Z","avatar_url":"https://github.com/sombriks.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# [sample-htmx-chi][repo]\n\nSample project using [htmx][htmx], [chi][chi] framework and [liquid][liquid]\n[template][go-liquid] engine in [go][go].\n\nSimilar experiment to the others seen [here][benchmark].\n\n## Requirements\n\n- go 1.20 or newer\n- [chi][chi] 5.0 or newer\n- [(go) liquid][go-liquid] 1.3 or newer\n- [gorm][gorm] 1.25 or newer\n- [htmx 1.9][urn-pkg] or newer (cached in assets folder)\n\n## How to build\n\n```bash\ngo build\n```\n\n## How to run\n\n```bash\ngo run main.go\n```\n\nOr\n\n```bash\n./sample-htmx-chi\n```\n\nNote that the execution point is important, the server must get the proper path\nto the [assets][assets] and [templates][templates] folders.\n\n## Noteworthy\n\n- Go has a strong culture of avoid 3rd party libraries imprinted on its\n  community. it does have, however, a rich set of libraries to ease the work.\n- There is a default template engine already available in the go runtime. It\n  does not, however, compare with more complex ones (i.e. no inheritance,\n  control flow and so on), so we added a custom one. \n- To be as close as possible to the other samples, i've added an\n  [ORM framework][gorm] so we get some goodies and some overhead.\n- Several helpers that comes \"for free\" in other stacks need to be done\n  \"by hand\" in go. some parameter converters and a few id checks for example. \n\n\n## Benchmark results\n\nThe following results for the same test applied\n[against the other versions][benchmark].\n\n```bash\n          /\\      |‾‾| /‾‾/   /‾‾/   \n     /\\  /  \\     |  |/  /   /  /    \n    /  \\/    \\    |     (   /   ‾‾\\  \n   /          \\   |  |\\  \\ |  (‾)  | \n  / __________ \\  |__| \\__\\ \\_____/ .io\n\n     execution: local\n        script: benchmark-koa.js\n        output: -\n\n     scenarios: (100.00%) 1 scenario, 10 max VUs, 1m0s max duration (incl. graceful stop):\n              * default: 10 looping VUs for 30s (gracefulStop: 30s)\n\n\n     ✓ 200 ok\n\n     checks.........................: 100.00% ✓ 93442       ✗ 0    \n     data_received..................: 377 MB  13 MB/s\n     data_sent......................: 7.5 MB  249 kB/s\n     http_req_blocked...............: avg=2.52µs  min=1.03µs   med=2.29µs  max=904.75µs p(90)=3.05µs  p(95)=3.45µs \n     http_req_connecting............: avg=26ns    min=0s       med=0s      max=310.49µs p(90)=0s      p(95)=0s     \n     http_req_duration..............: avg=3.11ms  min=757.8µs  med=2.99ms  max=10.38ms  p(90)=4.31ms  p(95)=4.79ms \n       { expected_response:true }...: avg=3.11ms  min=757.8µs  med=2.99ms  max=10.38ms  p(90)=4.31ms  p(95)=4.79ms \n     http_req_failed................: 0.00%   ✓ 0           ✗ 93442\n     http_req_receiving.............: avg=41.33µs min=14.34µs  med=39.33µs max=3.16ms   p(90)=53.41µs p(95)=59.64µs\n     http_req_sending...............: avg=10.99µs min=5.14µs   med=10.25µs max=782.44µs p(90)=14.9µs  p(95)=17.2µs \n     http_req_tls_handshaking.......: avg=0s      min=0s       med=0s      max=0s       p(90)=0s      p(95)=0s     \n     http_req_waiting...............: avg=3.06ms  min=724.42µs med=2.93ms  max=10.33ms  p(90)=4.26ms  p(95)=4.73ms \n     http_reqs......................: 93442   3114.471413/s\n     iteration_duration.............: avg=3.19ms  min=823.97µs med=3.07ms  max=10.48ms  p(90)=4.4ms   p(95)=4.87ms \n     iterations.....................: 93442   3114.471413/s\n     vus............................: 10      min=10        max=10 \n     vus_max........................: 10      min=10        max=10 \n\n\nrunning (0m30.0s), 00/10 VUs, 93442 complete and 0 interrupted iterations\ndefault ✓ [======================================] 10 VUs  30s\n```\n\n[repo]: https://github.com/sombriks/sample-htmx-chi\n[htmx]: https://htmx.org\n[chi]: https://go-chi.io\n[liquid]: https://shopify.github.io/liquid/basics/introduction/\n[go-liquid]: https://github.com/osteele/liquid\n[gorm]: https://gorm.io/docs/index.html\n[go]: https://go.dev/\n[urn-pkg]: https://unpkg.com/htmx.org@1.9.11/dist/htmx.min.js\n[benchmark]: https://github.com/sombriks/node-vs-kotlin-k6-benchmark\n[assets]: ./app/assets\n[templates]: ./app/templates\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsombriks%2Fsample-htmx-chi","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsombriks%2Fsample-htmx-chi","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsombriks%2Fsample-htmx-chi/lists"}