Skip to content

Reject functions with not enough parameters on strict mode #17868

@inad9300

Description

@inad9300

As is well explained in the FAQ, "functions with fewer parameters [are] assignable to functions that take more parameters."

This is fine to ease the transition from JavaScript, but limits TypeScript's ability to detect errors at compile time. A compiler flag to switch on this check would be an amazing step towards safer code.

This option may also be enabled by the "strict" flag.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Working as IntendedThe behavior described is the intended behavior; this is not a bug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions