We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
微信小程序
小程序基础库: 无关 使用框架: React
? 请选择框架 React ? 是否需要使用 TypeScript ? Yes ? 请选择 CSS 预处理器(Sass/Less/Stylus) Sass ? 请选择编译工具 Webpack5 ? 请选择包管理工具 npm ? 请选择模板源 Gitee(最快) ✔ 拉取远程模板仓库成功! ? 请选择模板 taro-ui(使用 taro-ui 的模板)
npm ERR! Found: [email protected] npm ERR! node_modules/react npm ERR! react@"^18.0.0" from the root project npm ERR! peer react@">=16.13.0" from [email protected] npm ERR! node_modules/taro-ui npm ERR! taro-ui@"^3.2.1" from the root project npm ERR! 1 more (react-dom) npm ERR! npm ERR! Could not resolve dependency: npm ERR! peer react@"18.2.0" from [email protected] npm ERR! node_modules/react-native npm ERR! peer react-native@">=0.62.0" from [email protected] npm ERR! node_modules/taro-ui npm ERR! taro-ui@"^3.2.1" from the root project
能新建项目
依赖错误
👽 Taro v3.6.28 Taro CLI 3.6.28 environment info: System: OS: Linux 6.8 Ubuntu 24.04 LTS 24.04 LTS (Noble Numbat) Shell: 5.2.21 - /bin/bash Binaries: Node: 20.12.2 - ~/.nvm/versions/node/v20.12.2/bin/node npm: 10.5.0 - ~/.nvm/versions/node/v20.12.2/bin/npm npmPackages: @tarojs/cli: 3.6.28 => 3.6.28 @tarojs/helper: 3.6.28 => 3.6.28 @tarojs/plugin-framework-react: 3.6.28 => 3.6.28 @tarojs/plugin-platform-alipay: 3.6.28 => 3.6.28 @tarojs/plugin-platform-h5: 3.6.28 => 3.6.28 @tarojs/plugin-platform-jd: 3.6.28 => 3.6.28 @tarojs/plugin-platform-qq: 3.6.28 => 3.6.28 @tarojs/plugin-platform-swan: 3.6.28 => 3.6.28 @tarojs/plugin-platform-tt: 3.6.28 => 3.6.28 @tarojs/plugin-platform-weapp: 3.6.28 => 3.6.28 @tarojs/react: 3.6.28 => 3.6.28 @tarojs/runtime: 3.6.28 => 3.6.28 @tarojs/shared: 3.6.28 => 3.6.28 @tarojs/taro: 3.6.28 => 3.6.28 @tarojs/taro-loader: 3.6.28 => 3.6.28 @tarojs/webpack5-runner: 3.6.28 => 3.6.28 babel-preset-taro: 3.6.28 => 3.6.28 eslint-config-taro: 3.6.28 => 3.6.28 react: ^18.0.0 => 18.3.1
The text was updated successfully, but these errors were encountered:
因为 taro-ui 的 peerDependencies 包含 react-native,有两个解决方案:
taro-ui
react-native
npm install -legacy-peer-deps
Sorry, something went wrong.
No branches or pull requests
相关平台
微信小程序
小程序基础库: 无关
使用框架: React
复现步骤
? 请选择框架 React
? 是否需要使用 TypeScript ? Yes
? 请选择 CSS 预处理器(Sass/Less/Stylus) Sass
? 请选择编译工具 Webpack5
? 请选择包管理工具 npm
? 请选择模板源 Gitee(最快)
✔ 拉取远程模板仓库成功!
? 请选择模板 taro-ui(使用 taro-ui 的模板)
npm ERR! Found: [email protected]
npm ERR! node_modules/react
npm ERR! react@"^18.0.0" from the root project
npm ERR! peer react@">=16.13.0" from [email protected]
npm ERR! node_modules/taro-ui
npm ERR! taro-ui@"^3.2.1" from the root project
npm ERR! 1 more (react-dom)
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer react@"18.2.0" from [email protected]
npm ERR! node_modules/react-native
npm ERR! peer react-native@">=0.62.0" from [email protected]
npm ERR! node_modules/taro-ui
npm ERR! taro-ui@"^3.2.1" from the root project
期望结果
能新建项目
实际结果
依赖错误
环境信息
The text was updated successfully, but these errors were encountered: