PHP 7.4.33
Preview: index.js Size: 452 B
/var/www/coop-podio-sms.bitkit.dk/httpdocs/node_modules/pkg-dir/index.js
'use strict';
const path = require('path');
const findUp = require('find-up');

const pkgDir = async cwd => {
	const filePath = await findUp('package.json', {cwd});
	return filePath && path.dirname(filePath);
};

module.exports = pkgDir;
// TODO: Remove this for the next major release
module.exports.default = pkgDir;

module.exports.sync = cwd => {
	const filePath = findUp.sync('package.json', {cwd});
	return filePath && path.dirname(filePath);
};

Directory Contents

Dirs: 0 × Files: 5
Name Size Perms Modified Actions
1.04 KB lrw-r--r-- 1985-10-26 08:15:00
Edit Download
452 B lrw-r--r-- 1985-10-26 08:15:00
Edit Download
1.08 KB lrw-r--r-- 1985-10-26 08:15:00
Edit Download
1.93 KB lrw-r--r-- 2024-05-28 16:34:57
Edit Download
1.25 KB lrw-r--r-- 1985-10-26 08:15:00
Edit Download
If ZipArchive is unavailable, a .tar will be created (no compression).