Skip to content
This repository was archived by the owner on Jan 25, 2022. It is now read-only.
This repository was archived by the owner on Jan 25, 2022. It is now read-only.

Optional spread syntax #55

@justinfagnani

Description

@justinfagnani

Spread for arrays and function calls is not null-safe (though it is for object spread).

It'd be very convenient to write them as:

const arr = [...?listOne, ...?listTwo];
foo(...?args);

Instead of:

const arr = [...listOne || [], ...listTwo || []];
foo(...args || []);

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions