@ursi/jim
v0.2.2
Published
JavaScript in Elm
Downloads
5
Readme
This is the JavaScript component for Jim
Install: npm install @ursi/jim
Use
// import
const jim = require(`@ursi/jim`);
/*
Attach a function to a Jim task
- The first value is a string used to identify the function in Jim.
- The second value is a function whose return value will be decoded in Jim.
If the return value is a promise, the task will complete when it settles.
*/
jim.task(`my task`, myTask);
/*
Attach a function to a Jim fuction
- The first value is a string used to identify the function in Jim.
- The second value is a syncronous function whose return value will be decoded in Jim.
*/
jim.function(`my function`, myFunction);