mirror of
https://github.com/pnpm/pnpm.git
synced 2026-04-27 10:30:58 -04:00
fix: use esm import for @pnpm/patch-package in @pnpm/apply-patch (#10191)
This commit is contained in:
5
.changeset/odd-keys-judge.md
Normal file
5
.changeset/odd-keys-judge.md
Normal file
@@ -0,0 +1,5 @@
|
||||
---
|
||||
"@pnpm/patching.apply-patch": patch
|
||||
---
|
||||
|
||||
Import `@pnpm/patch-package/dist/applyPatches` using `.js` extension for ESM compatibility. This fixes an `ERR_MODULE_NOT_FOUND` error.
|
||||
2
__typings__/local.d.ts
vendored
2
__typings__/local.d.ts
vendored
@@ -113,7 +113,7 @@ declare module 'yaml-tag' {
|
||||
export = anything
|
||||
}
|
||||
|
||||
declare module '@pnpm/patch-package/dist/applyPatches' {
|
||||
declare module '@pnpm/patch-package/dist/applyPatches.js' {
|
||||
export function applyPatch (opts: any): boolean
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { PnpmError } from '@pnpm/error'
|
||||
import { applyPatch } from '@pnpm/patch-package/dist/applyPatches'
|
||||
import { applyPatch } from '@pnpm/patch-package/dist/applyPatches.js'
|
||||
import { globalWarn } from '@pnpm/logger'
|
||||
|
||||
export interface ApplyPatchToDirOpts {
|
||||
|
||||
Reference in New Issue
Block a user