lib/index.js
function fn(modelGetter, opts) {
    if (typeof modelGetter !== 'function') {
        throw new Error(`'modelGetter' must be a function.`);
    }
    for (const key in actions) {
        let action = actions[key];
        if (opts.override && (typeof opts.override[key] === 'function')) {
            action = opts.override[key];
        }
        actions[key] = action(modelGetter, opts);
    }
    module.exports = actions;
    return actions;
}
function fn(modelGetter, opts) {
    if (typeof modelGetter !== 'function') {
        throw new Error(`'modelGetter' must be a function.`);
    }
    for (const key in actions) {
        let action = actions[key];
        if (opts.override && (typeof opts.override[key] === 'function')) {
            action = opts.override[key];
        }
        actions[key] = action(modelGetter, opts);
    }
    module.exports = actions;
    return actions;
}
入口文件