open-explorer-cross-platform
v1.0.3
Published
A cross platform NodeJs module to open a folder in the native os file system
Downloads
51
Maintainers
Readme
open-explorer-cross-platform
A cross platform NodeJs module to open a folder in the native os file system.
Installation
npm install open-explorer-cross-platform
or
yarn add open-explorer-cross-platform
Usage
import openExplorer from 'open-explorer-cross-platform';
await openExplorer('path/to/folder');
Or if you want for some reason to force a specific platform:
import openExplorer, { Platform } from 'open-explorer-cross-platform';
const platform: Platform = 'linux'; // or 'win32' or 'darwin'
await openExplorer('path/to/folder', platform);
Typings exported
export type Platform = 'linux' | 'win32' | 'darwin';