Tuesday 13 December 2016

npm module with optional cli?

Does anyone know if its possible (or can point me to a guide) on exposing both a CLI and a module interface in my module?I want to be able to do this:// module const foo = require('foo'); foo.bar(); // or: npm -g install foo $ foo bar

Submitted December 14, 2016 at 03:44AM by agentf90

No comments:

Post a Comment