Skip to content

Array with min length, and more #23528

@bluelovers

Description

@bluelovers

TypeScript Version: 2.7.0-dev.201xxxxx

Search Terms:

Code

need something like [string, string, ...argv] or [string, string] & string[]

abc(['', '', ''])

function abc(data: [string, string] & string[]){}

Expected behavior:

allow a array with length >= 2

Actual behavior:

array length only allow 2

Playground Link:

Related Issues:

Metadata

Metadata

Assignees

No one assigned

    Labels

    QuestionAn issue which isn't directly actionable in code

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions