kendo-react icon indicating copy to clipboard operation
kendo-react copied to clipboard

[Bug] kendo-react-pdf-viewer v6.1.0 with yarn v2+ (probably even v1) install bug + solution

Open iexa opened this issue 2 years ago • 0 comments

I'm submitting a bug report with the fix included.

Current behavior

When installing yarn add @progress/kendo-react-pdf-viewer I git this error: ➤ YN0001: │ Error: @typescript/lib-dom@npm:@types/web isn't supported by any available resolver

This should not be a problem, as all the other kendo-react components install just fine.

After researching I figured the problem is with yarn's package naming resolver, exactly with this line in the package.json file:

  "dependencies": {

    "@typescript/lib-dom": "npm:@types/web",

  },

The working fix is just 7 extra characters in package.json

The line just need to be modified to specify a range for this aliased dependency. Like this:

    "@typescript/lib-dom": "npm:@types/web@latest",

Expected behavior

Installing without an error.

Minimal reproduction of the problem with instructions

Just use yarn as a package manager to install kendo-react-pdf-viewer

What is the motivation or use case for changing the behavior?

To not error out when installing this package with yarn. And to be able to install it like the rest of the kendo ui packages from npm.

Environment

Package versions: v6.1 and older

Package manager: Yarn v2+, probably even v1 as well.

System:

  • Node version: v18.18.2
  • Platform: Windows 11 x64 22H2

iexa avatar Nov 04 '23 15:11 iexa