[refactor] web server routing system (#270)
* [refactor] web server routing system * regex literal * Docs
This commit is contained in:
1 parent
a710a23444
commit
7e5b2246fa
25 files changed
+820
-656
No files matched your search
@@ -0,0 +1,18 @@
|
||||
namespace Http
|
||||
|
||||
class HomeRouter extends HttpRouter
|
||||
|
||||
function new()
|
||||
super()
|
||||
end function
|
||||
|
||||
@get("/")
|
||||
function GoHome(context as object) as boolean
|
||||
response = context.response
|
||||
response.Redirect("/index.html")
|
||||
return true
|
||||
end function
|
||||
|
||||
end class
|
||||
|
||||
end namespace
|
||||
Reference in new issue
Block a user