Skip to content

Commit 7bfdc80

Browse files
committed
Add solution 03 - Optional Property ?:
1 parent a04faf2 commit 7bfdc80

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/03-optional-properties.problem.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import { expect, it } from "vitest";
22

3-
export const getName = (params: { first: string; last: string }) => {
3+
export const getName = (params: { first: string; last?: string }) => {
44
if (params.last) {
55
return `${params.first} ${params.last}`;
66
}

0 commit comments

Comments
 (0)