← Code LabTypeScript0/50 solved · 0%
Control Flow · medium

34. User-Defined Type Guards

Functions that signal a type change to the compiler.

Write `isString(val)` using `val is string` return type.
Required in your answer: val is string