TanStackOSS
    ai
    fix(ai-mcp): add shims to bin bundle for CJS dynamic-require compat (#754) * fix(ai-mcp): add shims to bin bundle for CJS dynamic-require compat json-schema-to-typescript (inlined via noExternal) uses dynamic require() calls internally. When bundled into an ESM output the global require is absent, causing the CLI to crash on startup with "Dynamic require of 'fs' is not supported" before it can parse any args. shims: true makes tsup inject a createRequire-based shim at the top of the bundle so CJS dependencies can call require() safely from within the ESM output. Fixes #753 * chore: add changeset for ai-mcp CLI dynamic-require shim fix * ci: apply automated fixes --------- Co-authored-by: Alem Tuzlak <t.zlak@hotmail.com> Co-authored-by: autofix-ci[bot] <114827586+autofix-ci[bot]@users.noreply.github.com>
    nx run-many --targets=build --exclude=examples/**,testing/**
Succeeded
CI Pipeline Execution

nx run-many --targets=build --exclude=examples/**,testing/**

Click to copy
Linux
4 CPU cores
read access token used
8c65dade777
97%

Cache hits

32 of 33 tasks used cache.

Get faster results

Learn how to enable distribution.

Atomizer enabled

33 groups of tasks optimized.

© 2026 - Nx Cloud

Terms of ServicePrivacy PolicyChangelogStatusDocsContact Nx CloudPricingCompany@NxDevTools