Skip to content

Docs: Outdated statement on index signature #2525

Description

Page URL: On “Object Types” under “ Index Signatures”: https://www.typescriptlang.org/docs/handbook/2/objects.html#index-signatures

Issue: There is this statement:

An index signature property type must be either ‘string’ or ‘number’.

But since TypeScript 4.4 not only number and string are allowed, but also symbol, template string patterns, and union types consisting only of these. https://www.typescriptlang.org/docs/handbook/release-notes/typescript-4-4.html#symbol-and-template-string-pattern-index-signatures

Recommended Fix: I created #2439 some time ago but nobody looked at it yet. :-( Would be nice if someone can take a look and either merge it or give feedback what is wrong with it.

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