View definition

(*Router).LoadRoutesFile

Defined in github.com/gernest/utron/routes.go

Description

LoadRoutesFile loads routes from a json file. Example of the routes file.

{
	"routes": [
		"get,post;/hello;Sample.Hello",
		"get,post;/about;Hello.About"
	]
}

supported formats are json,toml and yaml with extension .json, .toml and .yml respectively.

TODO refactor the decoding part to a separate function? This part shares the same logic as the one found in NewConfig()

LoadRoutesFile is referenced in 1 repository

github.com/gernest/utron