exists-stat

Synchronously check if a path exists and returns its stats object if it does

MIT 1 个版本
安装
npm install exists-stat
yarn add exists-stat
pnpm add exists-stat
bun add exists-stat
README

exists-stat

Synchronously check if a path exists and returns its stats object if it does. Saves you from needing try-catch statements when trying to get stats information.

existsStat('exists-dir').isDirectory(); // true
existsStat('exists.js').isFile();       //true

existsStat('does-not-exist-dir'); // null
existsStat('does-not-exist.js');  // null
版本列表
1.0.0 2017-03-18