Skip to content

Collection.currentStateAsChanges JSDoc examples don’t match CurrentStateAsChangesOptions #2261

Open

Description

@SimonVadier
  • I've validated the bug against the latest version of DB packages

Describe the bug

The JSDoc on Collection.currentStateAsChanges documents options that the method's type doesn't accept:

  1. whereExpression: eq(row.status, 'active'): CurrentStateAsChangesOptions has no whereExpression field.
  2. where: (row) => row.status === 'active': where is typed BasicExpression<boolean>, not a callback, so this example doesn't type-check either.

To Reproduce

  1. Create a collection
  2. Try JSDoc examples from currentStateAsChanges

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions