Comment

Comment by alex-zierhut

AS far as I know, this is because it was and still is common practice to return a result from a function, but return false if something didn't work. Having this type helps return type declaration like: false|ResultObject

In my opinion, using Exceptions or nullable types is a better practice in those cases, but I am not against having more options.

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton