Skip to content

Switch tsconfig to nodenext (blocked by @modelcontextprotocol/ext-apps) #674

@harijoe

Description

@harijoe

Context

#673 enabled biome's useImportExtensions lint rule to enforce .js suffixes on relative imports in packages/core. This prevents ESM runtime crashes (ERR_MODULE_NOT_FOUND) when a developer forgets the extension.

However, the ideal fix is switching moduleResolution from bundler to nodenext in packages/core/tsconfig.json, so tsc itself rejects missing extensions at compile time rather than relying on a lint rule.

Problem

@modelcontextprotocol/ext-apps@1.3.2 ships .d.ts files with extensionless specifiers:

// dist/src/app.d.ts
export { PostMessageTransport } from "./message-transport";
export * from "./types";

Under nodenext, TypeScript can't resolve these, causing errors like:

  • TS2305: Module '"@modelcontextprotocol/ext-apps"' has no exported member 'McpUiResourceMeta'
  • TS2460: Module declares 'McpUiHostContext' locally, but it is exported as 'PostMessageTransport'

Next steps

  • File an issue or PR upstream on modelcontextprotocol/ext-apps to add .js extensions in their declaration files
  • Once fixed upstream, switch packages/core/tsconfig.json to module: "nodenext" / moduleResolution: "nodenext" and remove the biome project domain workaround

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions