1aec706943 | ||
---|---|---|
.. | ||
commands | ||
data | ||
README.md | ||
index.js |
README.md
Tools
Adding a New Command
- Open
commands.js
and add a new object with command, description, and action keys. Action value must be a valid function name. - Open
data/actions.js
and add a function. The function name must be the value ofAction
from the first step.
Sample function:
export function* helloWorld() {
yield runCommand( 'Hello World', function* () {
console.log('Hello World');
} );
}
- Run
npm start
to compile and test.