Stone.js API
    Preparing search index...
    • What a budget belongs to, route-wise: one bucket per route, named by its declared path.

      Both halves are load-bearing, and both were learnt from a limiter that got them wrong. Keying on the handler alone made every endpoint of a controller share one bucket, so a request to one route silently ate another's budget, under whichever limit happened to apply. Keying on the live pathname goes too far the other way: a path carries resource codes, so rotating a code in the URL hands out a brand-new budget.

      Parameters

      • route: RouteLike

        The matched route, when there is one.

      • fallback: string

        What to use when there is no route, normally the event's pathname.

      Returns string

      The scope.