Slither.Stage.Router (Slither v0.1.0)

Copy Markdown View Source

Stage that routes items to named outputs based on predicates.

Routes are evaluated in order; the first matching predicate determines the destination. Items that match no route go to :default.

Options

  • :routes - List of {predicate, destination} tuples where predicate is (Slither.Item.t() -> boolean()) and destination is an atom.