looksLikeType

tcmts.cli.pages.looksLikeType · #s4ao2jjp · term · runs anywhere

Whether the finder takes q as a type: anything starting with :, or that looks like one ((xs: T[]) => T).

export function looksLikeType(q: string): boolean {
  return q.startsWith(":") || /=>|^\(|<.*>|\[\]$/.test(q);
}

used by