#return turn inferred as void instead of undefined

1 messages · Page 1 of 1 (latest)

craggy anvilBOT
#
m.a.t.t.t#0

Preview:ts type X = () => boolean | undefined type O = Record<string, X> const x: O = { test: () => {}, }

lone warren
#

yeah, not returning a value is semantically not the same as returning undefined

#

void means "my return type is not useful" or "don't care about the return type"