feat: add dashboard setup with esbuild + chakra-ui

This commit is contained in:
Lakhan Samani
2021-12-29 11:56:19 +05:30
parent df192bed4d
commit cf4d94a7aa
16 changed files with 1925 additions and 8 deletions

View File

@@ -32,10 +32,10 @@ func main() {
router := router.InitRouter()
router.LoadHTMLGlob("templates/*")
// login page app related routes.
// if we put them in router file then tests would fail as templates or build path will be different
if !constants.DISABLE_LOGIN_PAGE {
router.LoadHTMLGlob("templates/*")
app := router.Group("/app")
{
app.Static("/build", "app/build")
@@ -44,5 +44,11 @@ func main() {
}
}
app := router.Group("/dashboard")
{
app.Static("/build", "dashboard/build")
app.GET("/", handlers.DashboardHandler())
}
router.Run(":" + constants.PORT)
}