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

Remove typos in README file #144

Open
wants to merge 1 commit into
base: dev
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@ More details on the [official documentation](https://jestjs.io/docs/en/configura
You can use `module-alias` within another NPM package, however there are a few things to take into consideration.

1. As the aliases are global, you should make sure your aliases are unique, to avoid conflicts with end-user code, or with other libraries using module-alias. For example, you could prefix your aliases with '@my-lib/', and then use require('@my-lib/deep').
2. The internal "register" mechanism may not work, you should not rely on `require('module-alias/register')` for automatic detection of `package.json` location (where you defined your aliases), as it tries to find package.json in either the current working directory of your node process, or two levels down from node_modules/module-alias. It is extremely likely that this is end-user code. So, instead, your should either register aliases manually with `moduleAlias.addAlias`, or using something like `require('module-alias')(__dirname)`.
2. The internal "register" mechanism may not work, you should not rely on `require('module-alias/register')` for automatic detection of `package.json` location (where you defined your aliases), as it tries to find package.json in either the current working directory of your node process, or two levels down from node_modules/module-alias. It is extremely likely that this is end-user code. So, instead, you should either register aliases manually with `moduleAlias.addAlias`, or using something like `require('module-alias')(__dirname)`.

Here is an [example project](https://github.com/Kehrlann/module-alias-library).

Expand All @@ -199,7 +199,7 @@ If you are using this on an existing project, you can use [relative-to-alias](ht

If everyone who downloads module-alias would donate just $1, I would be a millionaire in 1 week!

I love contributing to open source, for free, but you know, sometimes, in the middle of the night, I may wan to eat.
I love contributing to open source, for free, but you know, sometimes, in the middle of the night, I may want to eat.

There are some improvements planned for module-alias and your donations will help a lot to make it happen faster.

Expand Down
Loading