mirror of
https://github.com/kataras/iris.git
synced 2025-12-27 06:47:08 +00:00
Update to 7.0.5 | Dynamic and static paths are not in conflict anymore.
Read more at: https://github.com/kataras/iris/blob/master/HISTORY.md Former-commit-id: b636d25c141ebdd5ad095ae9271433876a96e7ff
This commit is contained in:
@@ -30,9 +30,6 @@ func main() {
|
||||
|
||||
// the rest of the code stays the same.
|
||||
app := iris.New()
|
||||
// enable all (error) logs
|
||||
// select the httprouter as the servemux
|
||||
|
||||
// Attach the session manager we just created
|
||||
app.AttachSessionManager(mySessions)
|
||||
|
||||
|
||||
@@ -15,8 +15,6 @@ import (
|
||||
|
||||
func main() {
|
||||
app := iris.New()
|
||||
// enable all (error) logs
|
||||
// select the httprouter as the servemux
|
||||
|
||||
cookieName := "mycustomsessionid"
|
||||
// AES only supports key sizes of 16, 24 or 32 bytes.
|
||||
|
||||
@@ -14,9 +14,6 @@ type businessModel struct {
|
||||
|
||||
func main() {
|
||||
app := iris.New()
|
||||
// enable all (error) logs
|
||||
// select the httprouter as the servemux
|
||||
|
||||
mySessions := sessions.New(sessions.Config{
|
||||
// Cookie string, the session's client cookie name, for example: "mysessionid"
|
||||
//
|
||||
|
||||
@@ -134,8 +134,6 @@ func OnConnect(c websocket.Connection) {
|
||||
// ServerLoop listen and serve websocket requests
|
||||
func ServerLoop() {
|
||||
app := iris.New()
|
||||
// enable all (error) logs
|
||||
// select the httprouter as the servemux
|
||||
|
||||
ws := websocket.New(websocket.Config{Endpoint: "/socket"})
|
||||
ws.Attach(app)
|
||||
|
||||
@@ -25,8 +25,7 @@ type clientPage struct {
|
||||
|
||||
func main() {
|
||||
app := iris.New()
|
||||
// enable all (error) logs
|
||||
// select the httprouter as the servemux
|
||||
|
||||
app.AttachView(view.HTML("./templates", ".html")) // select the html engine to serve templates
|
||||
|
||||
ws := websocket.New(websocket.Config{
|
||||
|
||||
Reference in New Issue
Block a user