mux icon indicating copy to clipboard operation
mux copied to clipboard

Feature route middleware with `.Use`

Open cornejong opened this issue 1 month ago • 1 comments

What type of PR is this? (check all applicable)

  • [ ] Refactor
  • [x] Feature
  • [ ] Bug Fix
  • [ ] Optimization
  • [ ] Documentation Update
  • [ ] Go Version Update
  • [ ] Dependency Update

Description

Added support for route specific middleware using the .Use method. Using the .Use method on Route middlewares can be set on a specific route.

Example:

router.HandleFunc("/", handlerFunc).Use(middleware)

Related Tickets & Documents

  • Related Issue #
  • Closes #

Added/updated tests?

  • [x] Yes
  • [ ] No, and this is why:
  • [ ] I need help with writing tests

Run verifications and test

  • [x] make verify is passing
  • [x] make test is passing

cornejong avatar May 15 '24 16:05 cornejong