ts.data.json - v4.1.0
    Preparing search index...

    Function formatIssuePath

    • Renders a DecodingIssue path as a human-readable location string.

      Object keys are joined with dots, while array indices use bracket notation, matching the convention developers expect from JSON paths.

      Parameters

      • path: readonly (string | number)[]

        The structured path from the decoded root to the failing field.

      Returns string

      The location string (empty for a root-level issue).

      formatIssuePath(['user', 'name']); // 'user.name'
      formatIssuePath(['user', 'roles', 1]); // 'user.roles[1]'
      formatIssuePath([0, 'email']); // '[0].email'