Skip to content

Commit

Permalink
Merge branch 'feature/alova@3.x'
Browse files Browse the repository at this point in the history
  • Loading branch information
JOU-amjs committed Dec 28, 2024
2 parents 2a3c38b + 13cd630 commit b04b2a4
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions docs/tutorial/03-client/02-in-depth/02-method-matcher.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,10 +64,10 @@ const matchedMethods = alova.snaptshots.match({

## Match a single method instance

You can also set the second function of the `match` function to `true` to return the first item of the matching result, and return `undefined` if no match is found.
You can also set the second function of the `match` function to `false` to return the first item of the matching result, and return `undefined` if no match is found.

```js
const matchedSingleMethod = alova.snaptshots.match(/^todo/, true);
const matchedSingleMethod = alova.snaptshots.match(/^todo/, false);
```

## Limit instance snapshots
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,10 +64,10 @@ const matchedMethods = alova.snaptshots.match({

## 匹配单个 method 实例

你还可以将`match`函数的第二个函数设置为`true`返回匹配结果的第一项,未匹配到时返回`undefined`
你还可以将`match`函数的第二个函数设置为`false`返回匹配结果的第一项,未匹配到时返回`undefined`

```js
const matchedSingleMethod = alova.snaptshots.match(/^todo/, true);
const matchedSingleMethod = alova.snaptshots.match(/^todo/, false);
```

## 限制实例快照
Expand Down

0 comments on commit b04b2a4

Please sign in to comment.