chimp
Version:
Your development companion for doing quality, faster.
15 lines (14 loc) • 511 B
JavaScript
Object.defineProperty(exports, "__esModule", { value: true });
exports.findProjectMainPath = void 0;
const tslib_1 = require("tslib");
const find_package_json_1 = tslib_1.__importDefault(require("find-package-json"));
function findProjectMainPath() {
const f = (0, find_package_json_1.default)(process.cwd());
return f
.next()
.filename.split('/')
.filter((c) => !c.includes('package.json'))
.join('/');
}
exports.findProjectMainPath = findProjectMainPath;
;