Commit 5887c2ba authored by Sam Roberts's avatar Sam Roberts
Browse files

doc: improve description of module `exports`

- Do not use word alias, it isn't well defined
- Fix return value of require() example, which confusingly was not the
  exported API as it should have been.
- Fix the require() example, which claimed that the module exported `0`,
  when it exports `some_func`.
- Describe best practice in keeping exports and module.exports bound
  together.
- Describe why exports exists
- Remove reference to magic, which is also not well defined

PR-URL: https://github.com/nodejs/node/pull/9622


Reviewed-By: default avatarLuigi Pinca <luigipinca@gmail.com>
Reviewed-By: default avatarStephen Belanger <admin@stephenbelanger.com>
Reviewed-By: default avatarJames M Snell <jasnell@gmail.com>
parent f8a50333
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment