13 lines
348 B
JavaScript
Raw Normal View History

2018-03-25 21:29:35 -04:00
import ScriptContext from "./script_context.js";
async function executeBundle(bundle) {
const apiContext = ScriptContext(bundle.note, bundle.allNotes);
return await (function () {
return eval(`const apiContext = this; (async function() { ${bundle.script}\r\n})()`);
}.call(apiContext));
}
export default {
executeBundle
}