dfreire's programming blog home

24 Jun 2015

Using Echo to serve a static files folder

Echo is a micro web framework for go.

Here's a snippet for serving a static files folder:

package main

import (
    "github.com/labstack/echo"
)

func main() {
    e := echo.New()
    e.Static("/", "public") // Echo.Static(path, root string)
    e.Run(":3000")
}