A JavaScript based command line interface for web pages.
npm i cmdrjs
The cmdr
module is bundled using the standalone option in browserify which uses the umd library. This allows the module to be loaded in various ways.
The babel-polyfill is not included in the bundle. Older browsers and IE may require the polyfill for cmdrjs to function properly.
var cmdr = require('cmdr.js');
var terminal = new cmdr.Terminal(...);
require('cmdr.js', function(cmdr) {
var terminal = new cmdr.Terminal(...);
});
<script src="cmdr.js"></script>
<script>
var terminal = new cmdr.Terminal(...);
</script>
See the wiki for full documentation.
The cmdr
module is bundled with its dependencies and therefore has no external dependencies.
See package.json for accurate versions.