Skip to content

Condition callback function is not support Promise return in type #1726

Open
@liho00

Description

@liho00

Actual behavior
condition(fn, timeout): Promise
fn | () => boolean

  const success = await condition(
    async () => {         <---------------- why this line not support typescript?
    },
    {
      timeout: `1s`,
      interval: `1s`,
    }
  );

https://typescript.temporal.io/api/namespaces/workflow#condition

Expected behavior
condition(fn, timeout): Promise
fn | () => Promise

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions