UNPKG

computed-async-mobx

Version:

Define a computed by returning a Promise

15 lines (12 loc) 411 B
var fs = require("fs"), prefix = "var __decorate =", paths = [ "built/src/promisedComputed.js", "built/src/deprecatedComputedAsync.js", ]; paths.forEach(path => { // tell istanbul to ignore TS-generated decorator code var src = fs.readFileSync(path, "utf8"); src = src.replace(prefix, "/* istanbul ignore next */\n" + prefix); fs.writeFileSync(path, src); });