Created
January 14, 2020 08:35
-
-
Save SydBal/264a390d3fc34c9ca788378182a04775 to your computer and use it in GitHub Desktop.
NodeJS: Mapping argv to global
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
import { argv } from 'yargs' | |
Object.entries(argv).forEach(([key, value]) => { global[key] = value }) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment