Thunkified versions of popular
path
module functions.
$ npm install --save path-thunk
const pathThunk = require('path-thunk');
const thunk = pathThunk.join('path/to/some/dir');
thunk('foo', 'bar.js')
//=> equivalent to path.join('path/to/some/dir', 'foo', 'bar.js');
All functions accept partial input, and return thunks for the corresponding path
methods.
Node 0.12 and higher only
Both have identical API's to pathThunk
, but they always return windows
or posix
paths (respectively). This mirrors the corresponding items from the path
module.
MIT © James Talmage