Skip to content

Array.prototype.flat returns mixed on nested arrays #8999

@FezVrasta

Description

@FezVrasta

Flow version: 0.198.2

Expected behavior

The resulting array should be all numbers.

Actual behavior

The problem seems to be the type definition itself, why is it like that?
https://github.com/facebook/flow/blob/main/lib/core.js#L832

Metadata

Metadata

Assignees

No one assigned

    Labels

    Library definitionsIssues or pull requests about core library definitions

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions