New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

wair

Package Overview
Dependencies
Maintainers
1
Versions
2
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

wair

The wair command is roughly equivalent to the UNIX 'which' command but in Javascript.

latest
Source
npmnpm
Version
1.0.1
Version published
Maintainers
1
Created
Source

Wair

The Wair command is roughly equivalent to the UNIX 'which' command but in Javascript.

Windows, UNIX & POSIX

The default operation of the path module varies based on the operating system on which a Node.js application is running. Specifically, when running on a Windows operating system, the path module will assume that Windows-style paths are being used.

On Windows:
wair.basename('C:\\path\\example.html');
// Returns: 'C:\\path\\example.html'
wair.basename('C:\\path\\example.html');
// Returns: 'example.html'
On POSIX, UNIX and Windows:
wair.win32.basename('C:\\path\\example.html');
// Returns: 'example.html'
To achieve consistent results when working with POSIX file paths on any operating system, use wair.posix
On POSIX, UNIX and Windows:
wair.posix.basename('/path/example.html');
// Returns: 'example.html'

API Wair C9

WairCalls:


The wair.parse() method returns an object whose properties represent significant elements of the wair.
wair.parse(path)

The wair.normalize() method normalizes the given path,  segments '..' and '.' resolving.
wair.normalize(path)

wair.toNamespacedPath(path)

wair.sep
wair.relative(from, to)
wair.resolve([...paths])

wair.isAbsolute();
wair.win32

The wair.posix property provides access to POSIX specific implementations of the path methods.
wair.posix

The wair.unix property provides access to UNIX specific implementations of the path methods.
wair.unix

'''

Keywords

javascript

FAQs

Package last updated on 14 Oct 2019

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts