Created
September 1, 2022 22:21
-
-
Save Ivannnnn/8f8ecd59c074013028b5447da7c7854a to your computer and use it in GitHub Desktop.
This file contains 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
const select = (obj, propArr) => | |
propArr.reduce((acc, val) => { | |
acc[val] = obj[val]; | |
return acc; | |
}, {}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment