Optional Parameters
In TypeScript, every parameter is assumed to be required by the function. You can add a ? at the end of a parameter name to set it as optional.
For example, the lastName parameter of this function is optional:
function buildName(firstName: string, lastName?: string) {
// ...