export default function callIfFunction(thing: T | (() => T)): T;