Skip to content

Conversation

@clemyan
Copy link
Member

@clemyan clemyan commented Dec 12, 2025

DO NOT MERGE YET

This is stacked on top of #7009. I'll rebase this when that PR is merged.

What's the problem this PR addresses?

Some functionality (e.g. transpileModule) of TypeScript can run in browsers. However, out patched versions of TypeScript checks for PnP by accessing process.verions.pnp, which throws in browsers where process is not defined as a global.

Fixes #6944

How did you fix it?

This PR changes the PnP check to check for typeof process !== 'undefined' before checking process?.versions?.pnp

Checklist

  • I have set the packages that need to be released for my changes to be effective.
  • I will check that all automated PR checks pass before the PR gets reviewed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Bug?]: Yarn interferes with module resolution with Docusaurus and Webpack, node-modules linker

2 participants