command-manage 命令管理 Install npm install --save-dev command-manage Examples var command = require('command-manage')(); command.add({ name: 'moveBox', execute: function () { //body... }, undo: function () { //body... } });