JSPM

@simbo/accessible

1.0.1
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 7
  • Score
    100M100P100Q36941F
  • License MIT

A set of helper functions to check if files or directories are existing, readable, writable, or executable.

Package Exports

  • @simbo/accessible

Readme

Accessible

📦 @simbo/accessible

A lightweight utility library that provides reliable checks for file system accessibility.

It helps you determine whether files or directories are existing, readable, writable, or executable — with a simple, async-first API.

Features

  • Check if a file or directory exists

  • Verify if a path is readable, writable, or executable

  • Minimal and dependency-free

  • Fully typed TypeScript API

Installation

Install @simbo/accessible from the npm registry:

npm i [-D] @simbo/accessible

Usage

For a complete API reference, see the documentation.

Use the provided functions in your code:

import { isReadableFile, isWritableDirectory } from '@simbo/accessible';

if (await isReadableFile('path/to/file')) {
  console.log('File is readable');
}

if (await isWritableDirectory('path/to/directory')) {
  console.log('Directory is writable');
}

License

MIT © Simon Lepel