495d8ec3e16223b64c2675c4514421706e0224418dfb5d4161c569751e9b5a1adb802bef69a6858a9e8cbc046629d924cfe38c18586ffb4bf27c44d17e688d 735 B

12345678910111213141516171819202122232425262728293031
  1. # os-homedir [![Build Status](https://travis-ci.org/sindresorhus/os-homedir.svg?branch=master)](https://travis-ci.org/sindresorhus/os-homedir)
  2. > Node.js 4 [`os.homedir()`](https://nodejs.org/api/os.html#os_os_homedir) [ponyfill](https://ponyfill.com)
  3. ## Install
  4. ```
  5. $ npm install --save os-homedir
  6. ```
  7. ## Usage
  8. ```js
  9. const osHomedir = require('os-homedir');
  10. console.log(osHomedir());
  11. //=> '/Users/sindresorhus'
  12. ```
  13. ## Related
  14. - [user-home](https://github.com/sindresorhus/user-home) - Same as this module but caches the result
  15. - [home-or-tmp](https://github.com/sindresorhus/home-or-tmp) - Get the user home directory with fallback to the system temp directory
  16. ## License
  17. MIT © [Sindre Sorhus](https://sindresorhus.com)