Uploaded image for project: 'Node.js Driver'
  1. Node.js Driver
  2. NODE-3386

Add types for ListCollections cursor

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major - P3
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 4.0.0
    • Component/s: None
    • Labels:
      None
    • Documentation Changes:
      Not Needed

      Description

      Use Case

      As a node driver user
      I want better type hinting on ListCollections cursor response
      So that it's easier for me to use the driver API correctly

      The return type of the list collections method is pretty well defined, per the spec, so there is no reason for us not to provide a better type than just Document.

      Dependencies

      • None

      Unknowns

      • If added post 4.0 release, adding typings could result in compile time errors, so need to ensure it's done flexibly enough not to be a breaking change

      Acceptance Criteria

      • Provide a typescript type or interface for the ListCollections cursor return result
      Implementation Requirements
      • Cross reference the definition in the drivers spec for the list collections return type and add corresponding typescript hinting
      Testing Requirements
      • Add typescript tests for the new typing
      Documentation Requirements
      • None
      Follow Up Requirements
      • None

        Attachments

          Activity

            People

            Assignee:
            eric.adum Eric Adum (Inactive)
            Reporter:
            daria.pardue Daria Pardue
            Implementer:
            Neal Beeken Neal Beeken
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: