davidfig / pixi-viewport

A highly configurable viewport/2D camera designed to work with pixi.js
https://davidfig.github.io/pixi-viewport/
MIT License
1.04k stars 174 forks source link

can't install package #424

Open aram88888 opened 1 year ago

aram88888 commented 1 year ago

PS D:\aaaaaaaaaa> npm init This utility will walk you through creating a package.json file. It only covers the most common items, and tries to guess sensible defaults.

See npm help init for definitive documentation on these fields and exactly what they do.

Use npm install <pkg> afterwards to install a package and save it as a dependency in the package.json file.

Press ^C at any time to quit. package name: (aaaaaaaaaa) version: (1.0.0) description: entry point: (index.js) test command: git repository: keywords: author: license: (ISC) About to write to D:\aaaaaaaaaa\package.json:

{ "name": "aaaaaaaaaa", "version": "1.0.0", "description": "", "main": "index.js", "scripts": { "test": "echo \"Error: no test specified\" && exit 1" }, "author": "", "license": "ISC" }

Is this OK? (yes) y PS D:\aaaaaaaaaa> npm i pixi-viewport npm ERR! code ERESOLVE npm ERR! ERESOLVE unable to resolve dependency tree npm ERR! npm ERR! While resolving: aaaaaaaaaa@1.0.0 npm ERR! Found: @pixi/constants@6.5.9 npm ERR! node_modules/@pixi/constants npm ERR! peer @pixi/constants@"6.5.9" from @pixi/display@6.5.9 npm ERR! node_modules/@pixi/display npm ERR! peer @pixi/display@"^6.5.8" from pixi-viewport@4.38.0 npm ERR! node_modules/pixi-viewport npm ERR! pixi-viewport@"" from the root project npm ERR! peer @pixi/constants@"6.5.9" from @pixi/settings@6.5.9 npm ERR! node_modules/@pixi/settings npm ERR! peer @pixi/settings@"6.5.9" from @pixi/display@6.5.9 npm ERR! node_modules/@pixi/display npm ERR! peer @pixi/display@"^6.5.8" from pixi-viewport@4.38.0 npm ERR! node_modules/pixi-viewport npm ERR! pixi-viewport@"" from the root project npm ERR! peer @pixi/settings@"6.5.9" from @pixi/utils@6.5.9 npm ERR! node_modules/@pixi/utils npm ERR! peer @pixi/utils@"6.5.9" from @pixi/display@6.5.9 npm ERR! node_modules/@pixi/display npm ERR! peer @pixi/display@"^6.5.8" from pixi-viewport@4.38.0 npm ERR! node_modules/pixi-viewport npm ERR! 1 more (@pixi/utils) npm ERR! npm ERR! Could not resolve dependency: npm ERR! peer @pixi/constants@"6.5.8" from @pixi/core@6.5.8 npm ERR! node_modules/@pixi/core npm ERR! peer @pixi/core@"6.5.8" from @pixi/interaction@6.5.8 npm ERR! node_modules/@pixi/interaction npm ERR! peer @pixi/interaction@"^6.5.8" from pixi-viewport@4.38.0 npm ERR! node_modules/pixi-viewport npm ERR! pixi-viewport@"*" from the root project npm ERR! npm ERR! Fix the upstream dependency conflict, or retry npm ERR! this command with --force, or --legacy-peer-deps npm ERR! to accept an incorrect (and potentially broken) dependency resolution.

szge commented 1 year ago

try npm i pixi.js@7.1.3 then npm i pixi-viewport@5.0.0. You need pixi.js to install pixi-viewport.