node package manager
Painless code sharing. npm Orgs help your team discover, share, and reuse code. Create a free org »

expand-home-dir

expand-home-dir

Expand ~/

expandHomeDir = require('expand-home-dir')
 
expandHomeDir('~')
// => /Users/azer 
 
expandHomeDir('~/foo/bar/qux.corge')
// => /Users/azer/foo/bar/qux.corge 

Install

$ npm install expand-home-dir