docs: added .json modules.

This commit is contained in:
koichik 2011-10-13 17:06:27 +09:00
parent f243ca199b
commit 1b55010a04

View File

@ -98,10 +98,11 @@ return the built in HTTP module, even if there is a file by that name.
### File Modules ### File Modules
If the exact filename is not found, then node will attempt to load the If the exact filename is not found, then node will attempt to load the
required filename with the added extension of `.js`, and then `.node`. required filename with the added extension of `.js`, `.json`, and then `.node`.
`.js` files are interpreted as JavaScript text files, and `.node` files `.js` files are interpreted as JavaScript text files, and `.json` files are
are interpreted as compiled addon modules loaded with `dlopen`. parsed as JSON text files. `.node` files are interpreted as compiled addon
modules loaded with `dlopen`.
A module prefixed with `'/'` is an absolute path to the file. For A module prefixed with `'/'` is an absolute path to the file. For
example, `require('/home/marco/foo.js')` will load the file at example, `require('/home/marco/foo.js')` will load the file at