Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/kimlimjustin/is-hidden-file
Check if a file/folder is hidden on node js that works on any platform.
https://github.com/kimlimjustin/is-hidden-file
hidden-files node-js
Last synced: 3 months ago
JSON representation
Check if a file/folder is hidden on node js that works on any platform.
- Host: GitHub
- URL: https://github.com/kimlimjustin/is-hidden-file
- Owner: kimlimjustin
- License: mit
- Created: 2021-06-06T15:25:04.000Z (over 3 years ago)
- Default Branch: master
- Last Pushed: 2022-08-28T21:45:35.000Z (over 2 years ago)
- Last Synced: 2024-10-14T03:31:33.609Z (3 months ago)
- Topics: hidden-files, node-js
- Language: C++
- Homepage: https://www.npmjs.com/package/is-hidden-file
- Size: 52.7 KB
- Stars: 6
- Watchers: 2
- Forks: 3
- Open Issues: 3
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# is-hidden-file
[![npm version](https://img.shields.io/badge/dynamic/json?color=317EFB&logo=npm&style=for-the-badge&label=Version&query=version&url=https%3A%2F%2Funpkg.com%2Fis-hidden-file%40latest%2Fpackage.json)](https://www.npmjs.com/package/is-hidden-file)> Check if a file/folder is hidden on all platforms.
- Unix: Check file name starts with `.`.
- Windows: Check if file hidden using native code.## Installation
- npm: `npm i is-hidden-file`
- yarn: `yarn add is-hidden-file`## Usage
#### Node js
```js
const { isHiddenFile } = require("is-hidden-file");console.log(isHiddenFile(".git")) // true
console.log(isHiddenFile("README.md")) // false
```#### Node js with typescript
```ts
import { isHiddenFile } from "is-hidden-file";console.log(isHiddenFile(".git")) // true
console.log(isHiddenFile("README.md")) // false
```## License
MIT