Skip to content

npm install error #67

@Rektyfikowany

Description

@Rektyfikowany

执行npm install报错:

npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: [email protected]
npm ERR! Found: [email protected]
npm ERR! node_modules/solid-transition-group
npm ERR!   solid-transition-group@"^0.0.12" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer solid-transition-group@"^0.0.10" from @hope-ui/[email protected]
npm ERR! node_modules/@hope-ui/solid
npm ERR!   @hope-ui/solid@"0.6.7" 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.

如果npm install --legacy-peer-deps强制安装, npm run build则会报错:

[vite:esbuild-transpile] Transform failed with 1 error:
assets/Upload.2d6e03b0.js:4:0: ERROR: Transforming async generator functions to the configured target environment ("chrome64", "edge79", "es2020", "firefox67", "safari11.1" + 2 overrides) is not supported yet

Transforming async generator functions to the configured target environment ("chrome64", "edge79", "es2020", "firefox67", "safari11.1" + 2 overrides) is not supported yet
1  |  import { b6 as instance, _ as _password, o as objStore, d as useT, u as useRouter, e as createSignal, bw as createStore, f as createComponent, m as Show, a0 as HStack, B as Button, v as For, I as Input, W as VStack, a7 as getMainColor, n as notify, bf as Heading, Y as Box, aP as SelectWrapper, a6 as IconButton, bv as Checkbox, bc as Text, bx as Badge, t as createMemo, by as getFileSize, bz as Progress, bA as ProgressIndicator, p as pathJoin } from './index.db59f15c.js';
2  |  import { a as RiDocumentFolderUploadFill, b as RiDocumentFileUploadFill } from './index.8a3582fc.js';
3  |
   |   ^
4  |  async function* asyncPool(poolLimit, array, iteratorFn) {
   |  ^
5  |    const executing = /* @__PURE__ */ new Set();

error during build:
Error: Transform failed with 1 error:
assets/Upload.2d6e03b0.js:4:0: ERROR: Transforming async generator functions to the configured target environment ("chrome64", "edge79", "es2020", "firefox67", "safari11.1" + 2 overrides) is not supported yet

复现#55, #2833中的问题, 此时vite版本:

> [email protected] build
> vite build

vite v3.2.5 building for production...
✓ 595 modules transformed.

而使用pnpm install时, npm run build构建成功, 显示vite版本:

> [email protected] build
> vite build

vite v3.0.8 building for production...
✓ 595 modules transformed.

应该是package.json的依赖版本问题, 不过回溯几个commit都有相同问题

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions