Created
August 8, 2020 04:41
-
-
Save tomaspietravallo/4a21092756a6f6686780c30f2c0435b4 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* @param {} x | |
* @param {*} y | |
* @param {*} defaultValue | |
* @returns {Point2DSignal} | |
*/ | |
function checkAndPack2(x, y, defaultValue){ | |
let values = [x, y]; | |
values.map(x => x || R.val(defaultValue)); | |
return R.pack2(values[0], values[1]); | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment