Skip to content

Configuration

whereSlug()

whereSlug() — returns struct

Available in: mapper Category: Routing

Constrain a route variable to only match URL-friendly slug values (lowercase alphanumeric and hyphens).

NameTypeRequiredDefaultDescription
variableNamestringyesThe route variable name to constrain. Can also be a comma-delimited list.