Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

EJS Support #164

Open
SowinskiBraeden opened this issue Feb 13, 2022 · 0 comments
Open

EJS Support #164

SowinskiBraeden opened this issue Feb 13, 2022 · 0 comments

Comments

@SowinskiBraeden
Copy link

Create support for EJS for more manipulatable front end support. For example:

package main

import (
  "github.com/gofiber/fiber/v2"
  "github.com/gofiber/fiber/v2/template/ejs"
)

func main() {
  app := fiber.New(fiber.Config{
        Views: ejs.New("./views", ".ejs"),
  })

  app.Post("/", func (c *fiber.Ctx) error {
    return c.Render("index", fiber.Map{
          "myVariable": someRandomVariable,
      })
  })
}

Similar to how the regular html works, but enabling it for EJS

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants