11 lines
203 B
JavaScript
11 lines
203 B
JavaScript
// Pick the first defined of two or three arguments.
|
|
export default function defaults(a, b, c) {
|
|
if (a != null) {
|
|
return a;
|
|
}
|
|
if (b != null) {
|
|
return b;
|
|
}
|
|
return c;
|
|
}
|