mirror of
https://github.com/motajs/template.git
synced 2026-11-09 19:54:30 +08:00
chore: 将事件执行标记为 ignoreReplay
This commit is contained in:
1 parent
b623e8ac98
commit
aa3c7296c7
2 files changed
+5
-2
No files matched your search
@@ -179,8 +179,9 @@ export function shouldReplay(message: string): ReplayDecorator {
|
||||
/**
|
||||
* 将一个类的方法标记为忽略录像安全检查,一般用于异步内容等不是立刻会触发状态修改的方法,
|
||||
* 不要使用此方法来规避控制台的录像错误警告,否则很可能导致录像出错。
|
||||
* @param _msg 忽略录像记录的原因
|
||||
*/
|
||||
export function ignoreReplay(): ReplayDecorator {
|
||||
export function ignoreReplay(_msg: string): ReplayDecorator {
|
||||
return function <This, Args extends unknown[], Return>(
|
||||
this: This,
|
||||
method: ReplayMethod<This, Args, Return>
|
||||
|
||||
Reference in new issue
Block a user