Comment

Comment by lacampbell

Haven't had a coffee yet so go easy on me - doesn't this solve your issue?

    interface Functor<A> {
        map<B>(f: (a: A) => A): Functor<A>;
    }
You map over an option, you get an option. You map over an either, you get an either. etc etc.
parent lacampbell 7 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton