Skip to content

Commit f938fa0

Browse files
Update exemplar.js
1 parent 7742dcf commit f938fa0

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

exercises/concept/recycling-robot/.meta/exemplar.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ export class ElectronicDevice {
1111
* Checks if input is a boolean.
1212
*
1313
* @param {unknown} value
14-
* @returns {boolean} whether the input is a boolean
14+
* @returns {value is boolean} whether the input is a boolean
1515
*/
1616
export function isBoolean(value) {
1717
return typeof value === 'boolean';
@@ -21,7 +21,7 @@ export function isBoolean(value) {
2121
* Checks if input is a finite number or bigint.
2222
*
2323
* @param {unknown} value
24-
* @returns {boolean} whether the input is a finite number or bigint
24+
* @returns {value is number | bigint} whether the input is a finite number or bigint
2525
*/
2626
export function isNumber(value) {
2727
return (
@@ -35,7 +35,7 @@ export function isNumber(value) {
3535
* Checks if a value is an object.
3636
*
3737
* @param {unknown} value
38-
* @returns {boolean} whether the input is an object.
38+
* @returns {value is object} whether the input is an object.
3939
*/
4040
export function isObject(value) {
4141
return value !== null && typeof value === 'object';

0 commit comments

Comments
 (0)