assistsx-js 0.2.0 → 0.2.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -4
- package/dist/index.cjs +3 -3
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.mts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.global.js +9 -13
- package/dist/index.global.js.map +1 -1
- package/dist/index.js +3 -3
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/src/step.ts +3 -3
package/package.json
CHANGED
package/src/step.ts
CHANGED
|
@@ -22,7 +22,7 @@ export type StepInterceptor = (step: Step) => StepResult | Promise<StepResult>;
|
|
|
22
22
|
export class Step {
|
|
23
23
|
static delayMsDefault: number = 1000;
|
|
24
24
|
static readonly repeatCountInfinite: number = -1;
|
|
25
|
-
static repeatCountMaxDefault: number =
|
|
25
|
+
static repeatCountMaxDefault: number = 15;
|
|
26
26
|
static showLog: boolean = false;
|
|
27
27
|
static exceptionRetryCountMaxDefault: number = 3;
|
|
28
28
|
|
|
@@ -161,7 +161,7 @@ export class Step {
|
|
|
161
161
|
nextStep = await currentStep.impl?.(currentStep);
|
|
162
162
|
}
|
|
163
163
|
if (
|
|
164
|
-
currentStep.repeatCountMax
|
|
164
|
+
currentStep.repeatCountMax > Step.repeatCountInfinite &&
|
|
165
165
|
currentStep.repeatCount >= currentStep.repeatCountMax
|
|
166
166
|
) {
|
|
167
167
|
if (Step.showLog) {
|
|
@@ -378,7 +378,7 @@ export class Step {
|
|
|
378
378
|
repeatCount: number = 0;
|
|
379
379
|
|
|
380
380
|
/**
|
|
381
|
-
*
|
|
381
|
+
* 步骤重复执行最大次数,默认15次
|
|
382
382
|
*/
|
|
383
383
|
repeatCountMax: number = Step.repeatCountMaxDefault;
|
|
384
384
|
|