Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Main lib returns object, not path string #7

Closed
mhkeller opened this issue Mar 16, 2015 · 2 comments
Closed

Main lib returns object, not path string #7

mhkeller opened this issue Mar 16, 2015 · 2 comments

Comments

@mhkeller
Copy link

The docs should be updated to reflect that require('app-root-path') returns an object, not the path string. It should be .require('app-root-path').path.

https://github.com/inxilpro/node-app-root-path/blob/master/lib/app-root-path.js#L37

@inxilpro
Copy link
Owner

You actually don't have to use .path because the object provides a toString() method. So if you use the object like a string, it will behave like a string.

That said, it might not hurt to document that quirk.

inxilpro added a commit that referenced this issue Mar 17, 2015
Addresses concern brought up in
#7
@inxilpro
Copy link
Owner

The README.md has been updated. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants