Create a page
  • References/JavaScript/TypeScript/Tutorials

Create a page Create a file in src named index.html:

2025-01-10 15:47:30
Iterables
  • References/JavaScript/TypeScript/Iterators & Generators

Iterables An object is deemed iterable if it has an implementation for the

2025-01-10 15:47:30
Multi-file namespaces
  • References/JavaScript/TypeScript/Namespaces

Multi-file namespaces Here, we’ll split our Validation namespace across many files. Even though the files are separate, they can

2025-01-10 15:47:30
Use Optional Parameters
  • References/JavaScript/TypeScript/Declaration Files

Use Optional Parameters Don’t write several overloads that differ only in trailing parameters:

2025-01-10 15:47:30
Ambient Namespaces
  • References/JavaScript/TypeScript/Namespaces

Ambient Namespaces The popular library D3 defines its functionality in a global object called d3. Because this library is loaded

2025-01-10 15:47:30
Aliases
  • References/JavaScript/TypeScript/Namespaces

Aliases Another way that you can simplify working with of namespaces is to use import q = x.y.z to create shorter names for commonly-used

2025-01-10 15:47:30
Optional and Default Parameters
  • References/JavaScript/TypeScript/Functions

Optional and Default Parameters In TypeScript, every parameter is assumed to be required by the function. This doesn’t mean that it can’t be

2025-01-10 15:47:30
The JSX result type
  • References/JavaScript/TypeScript/JSX

The JSX result type By default the result of a JSX expression is typed as any. You can customize the type by specifying the JSX

2025-01-10 15:47:30
“Do”s and “Don’t”s
  • References/JavaScript/TypeScript/Declaration Files

“Do”s and “Don’t”s Many common mistakes in declaration files can be easily avoided. The

2025-01-10 15:47:30
export = and import = require()
  • References/JavaScript/TypeScript/Modules

export = and import = require() Both CommonJS and AMD generally have the concept of an exports object

2025-01-10 15:47:30