Example #1
0
func init() {
	http.Handle("/static/css/", http.StripPrefix("/static/css/", http.FileServer(http.Dir("../static/css"))))
	http.Handle("/static/js/", http.StripPrefix("/static/js/", http.FileServer(http.Dir("../static/js"))))
	http.Handle("/static/components/js/", http.StripPrefix("/static/components/js/", http.FileServer(http.Dir("../static/components/js"))))

	beegae.Router("/", &controllers.MainController{})
	beegae.Run()

	// api := rest.NewApi()
	// api.Use(rest.DefaultDevStack...)
	// router, err := rest.MakeRouter(
	// 	rest.Post("/api/v1/", PostDataHandler),
	// )

	// if err != nil {
	// 	log.Fatal(err)
	// }

	// api.SetApp(router)
	// http.Handle("/", api.MakeHandler())
	// http.Handle("/static/", http.StripPrefix("/static/", http.FileServer(http.Dir("static"))))

}
Example #2
0
func init() {
	beegae.Router("/todos", &controllers.MainController{})
	beegae.Run()
}
Example #3
0
func init() {
	beegae.Run()
}
Example #4
0
func (self *BeegoApp) Run() {

	beegae.Run()
}