This project is being migrated from Echo/Go to the Dirge Engine.
| Current (Echo/Go) | Dirge Engine |
|---|---|
| Manual route rebuilding | .dx templates with hot-reload |
| Recompile on every change | Live reload, edit and refresh |
| Custom caching implementation | Built-in 256-shard cache system |
| Manual HTML escaping | Auto-escaped ~{ } syntax |
| Separate admin setup | Dual-server architecture (8080/8081) |
| Custom plugin system | Sandboxed Lua plugins with hot-reload |
| ~20MB+ with dependencies | Single ~24MB binary, zero dependencies |
- Performance: 66k req/sec, <2ms latency, 13µs template rendering
- Security: Auto-escape HTML, prepared statements, path traversal protection, plugin sandboxing
- Simplicity: Single binary deployment, TOML configuration,
.dxtemplating - Extensibility: Lua plugins with event system, WordPress-style hooks
- Development: No recompilation, hot-reload everything
The imageboard will be rebuilt using Dirge's architecture:
/
├── home/ # Board pages (.dx templates)
├── admin-home/ # Admin panel (.dx templates)
├── internals/
│ └── plugins/ # Lua plugins (posting, moderation, etc.)
├── config.toml # Server configuration
└── routes.toml # Board/thread routing
Before (Go/Echo):
e.GET("/board/:name", func(c echo.Context) error {
board := c.Param("name")
// ... fetch threads, render template
return c.Render(200, "board.html", data)
})After (Dirge):
<!-- home/board.dx -->
~{ board = Param("name") }
~{ threads = DBQuery("SELECT * FROM threads WHERE board = ?", board) }
<h1>/~{ board }/</h1>
~{ for _, t in ipairs(threads) do }
<div class="thread">~{ t.content }</div>
~{ end }- Port board/thread rendering to
.dx - Migrate posting logic to Lua plugins
- Port admin panel to admin-home/
- Implement moderation via plugin events
- Configure caching in config.toml
See the pre-dirge branch for the original Echo/Go implementation.