News for hackers. Stuff that matters.
Re:Why I still Lisp by dmux on Monday February 01, 2021 @05:07PM (#25994718)
Instead of giving the interface an explicit name, I think you could instead use something like this:

    function getEmails(group: Array<{email: string}>) {
        return group.map((p) => p.email)
    }
which leaves the function more open ended than relying on an explicitly named interface that other types then have to inherit from.

There are no comments on this comment yet.