Skip to content

Global middleware #167

@teamon

Description

@teamon

Super useful, especially when using existing libraries like elixir-google-api

# global for all tesla-based clients
config :tesla, middleware: [MySuperMetrics]

# for specific client
config :tesla, GoogleApi.Datastore.V1.Connection, middleware: [MySuperMetrics]

# inserting middleware before/after stack
config :tesla, middleware: [
  pre: [ModuleA], 
  post: [ModuleB]
]

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions