V2EX = way to explore
V2EX 是一个关于分享和探索的地方
现在注册
已注册用户请  登录
爱意满满的作品展示区。
sox
V2EX  ›  分享创造

negative: 把 object 转换成命令行参数

  •  
  •   sox ·
    egoist · 2015-12-08 21:17:51 +08:00 · 1314 次点击
    这是一个创建于 3225 天前的主题,其中的信息可能已经有所发展或是发生改变。

    如果你用过 minimist, 那你就知道 negative 做的是刚好相反的事 XD

    https://github.com/egoist/negative 比如:

    import negative from 'negative';
    // return `command entry.js --verbose -o output.js`
    negative({
      _: ['entry.js'],
      verbose: true,
      o: 'output.js'
    }, 'command');
    
    目前尚无回复
    关于   ·   帮助文档   ·   博客   ·   API   ·   FAQ   ·   实用小工具   ·   1178 人在线   最高记录 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 23ms · UTC 17:21 · PVG 01:21 · LAX 10:21 · JFK 13:21
    Developed with CodeLauncher
    ♥ Do have faith in what you're doing.