Skip to content

Commit 85b26a5

Browse files
node.js -> Node.js
1 parent 697b6d5 commit 85b26a5

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

pages/Namespaces and Modules.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -204,8 +204,8 @@ If multiple JS files get produced, we'll need to use `<script>` tags on our webp
204204
# Going Modular
205205

206206
TypeScript also has the concept of modules.
207-
Modules are used in two cases: node.js and require.js.
208-
Applications not using node.js or require.js do not need to use modules and can best be organized using the namespaces, outlined above.
207+
Modules are used in two cases: Node.js and require.js.
208+
Applications not using Node.js or require.js do not need to use modules and can best be organized using the namespaces, outlined above.
209209

210210
When using modules, relationships between files are specified in terms of imports and exports at the file level.
211211
In TypeScript, any file containing a top-level `import` or `export` is considered a module.
@@ -222,7 +222,7 @@ import someMod = require('someModule');
222222

223223
We specify which objects are visible outside the module by using the `export` keyword on a top-level declaration, similarly to how `export` defined the public surface area of a namespace.
224224

225-
To compile, we must specify a module target on the command line. For node.js, use `--module commonjs`; for require.js, use `--module amd`. For example:
225+
To compile, we must specify a module target on the command line. For Node.js, use `--module commonjs`; for require.js, use `--module amd`. For example:
226226

227227
```Shell
228228
tsc --module commonjs Test.ts
@@ -286,7 +286,7 @@ strings.forEach(s => {
286286

287287
## Code Generation for Modules
288288

289-
Depending on the module target specified during compilation, the compiler will generate appropriate code for either node.js (commonjs) or require.js (AMD) module-loading systems.
289+
Depending on the module target specified during compilation, the compiler will generate appropriate code for either Node.js (commonjs) or require.js (AMD) module-loading systems.
290290
For more information on what the `define` and `require` calls in the generated code do, consult the documentation for each module loader.
291291

292292
This simple example shows how the names used during importing and exporting get translated into the module loading code.
@@ -420,7 +420,7 @@ For this pattern to work, it's important that the symbol defined via an `import`
420420
To maintain type safety, we can use the `typeof` keyword.
421421
The `typeof` keyword, when used in a type position, produces the type of a value, in this case the type of the module.
422422

423-
##### Dynamic Module Loading in node.js
423+
##### Dynamic Module Loading in Node.js
424424

425425
```TypeScript
426426
declare var require;

0 commit comments

Comments
 (0)