Skip to content

Commit ac0c37d

Browse files
committed
Update wording around matching handlers
1 parent a075332 commit ac0c37d

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

docs/sources/k6/next/javascript-api/k6-browser/page/route.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ description: 'Browser module: page.route(url, handler) method'
77

88
The method adds a route that allows modifying network requests matching the provided url. The handler is a function taking a [Route](https://grafana.com/docs/k6/<K6_VERSION>/javascript-api/k6-browser/route/) input that provides functions to [continue](https://grafana.com/docs/k6/<K6_VERSION>/javascript-api/k6-browser/route/continue), [fulfill](https://grafana.com/docs/k6/<K6_VERSION>/javascript-api/k6-browser/route/fulfill) or [abort](https://grafana.com/docs/k6/<K6_VERSION>/javascript-api/k6-browser/route/abort) the request. Once routing is enabled, every request matching the url pattern will stall unless one of these functions is called.
99

10-
When several routes match the given pattern, they run in the order opposite to their registration. That way the last registered route can always override all the previous ones.
10+
When several routes match the given pattern, only the last registered route handler will run, and all others will be skipped.
1111

1212
| Parameter | Type | Default | Description |
1313
| --------- | -------------------------------------------------------------------------------------------- | ------- | --------------------------------------------------- |

docs/sources/k6/next/javascript-api/k6-browser/route/_index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ weight: 12
88

99
Route represents a network request intercepted by the [`page.route()`](https://grafana.com/docs/k6/<K6_VERSION>/javascript-api/k6-browser/page/route) function and allows to modify its behavior. Once routing is enabled, every request intercepted by a route will stall unless it's continued, fulfilled or aborted.
1010

11-
When several routes match the given pattern, they run in the order opposite to their registration. That way the last registered route can always override all the previous ones.
11+
When several routes match the given pattern, only the last registered route handler will run, and all others will be skipped.
1212

1313
## Supported APIs
1414

0 commit comments

Comments
 (0)