Topics

Jump to a topic.

Search questions

Find a question by title, tag, or summary.

Chapter 06

Modules and declaration files

How TypeScript resolves and types modules: moduleResolution, ESM/CJS interop, .d.ts files, declare, and augmentation.
6 questions
  1. 010What do import type, isolatedModules, and verbatimModuleSyntax do?Coming soonmedium
  2. 020How does moduleResolution work, and when do you use bundler or nodenext?Coming soonhard
  3. 030Why does importing a CommonJS module sometimes fail, and what does esModuleInterop do?Coming soonhard
  4. 040What is a .d.ts file, and how do you write one for an untyped library?Coming soonmedium
  5. 050How do you augment a module or add a global type?Coming soonmedium
  6. 060How can you type-check JavaScript with TypeScript?Coming sooneasy