taro-calendar-customizable icon indicating copy to clipboard operation
taro-calendar-customizable copied to clipboard

taro项目依赖的react升级到最新版后,组件报错。

Open QingYuanO opened this issue 3 years ago • 4 comments

Invalid hook call. Hooks can only be called inside of the body of a function component. This could happen for one of the following reasons:

  1. You might have mismatching versions of React and the renderer (such as React DOM)
  2. You might be breaking the Rules of Hooks
  3. You might have more than one copy of React in the same app See https://reactjs.org/link/invalid-hook-call for tips about how to debug and fix this problem.

QingYuanO avatar Aug 03 '21 14:08 QingYuanO

taro 3.3.7 版本 Error: Minified React error #321; visit https://reactjs.org/docs/error-decoder.html?invariant=321 for the full message or use the non-minified dev environment for full errors and additional helpful warnings. at Z (._node_modules_taro-calendar-customizable_node_modules_react_cjs_react.production.min.js:19) at exports.useState (._node_modules_taro-calendar-customizable_node_modules_react_cjs_react.production.min.js:25) at Days (._node_modules_taro-calendar-customizable_src_pages_calendar_days_index.tsx:220) at le (._node_modules_react-reconciler_cjs_react-reconciler.production.min.js:74) at Ve (._node_modules_react-reconciler_cjs_react-reconciler.production.min.js:97) at Ue (._node_modules_react-reconciler_cjs_react-reconciler.production.min.js:95) at Se (._node_modules_react-reconciler_cjs_react-reconciler.production.min.js:94) at gh (._node_modules_react-reconciler_cjs_react-reconciler.production.min.js:188) at fh (._node_modules_react-reconciler_cjs_react-reconciler.production.min.js:167) at eh (._node_modules_react-reconciler_cjs_react-reconciler.production.min.js:167)

houhoz avatar Sep 08 '21 15:09 houhoz

package.json

  "peerDependencies": {
    "react": "^17.0.2"
  },

felix9ia avatar Jul 31 '22 10:07 felix9ia

同样报错! https://reactjs.org/docs/error-decoder.html?invariant=321

"@tarojs/taro": "3.3.16",
"taro-calendar-customizable": "^2.1.2",

node 16.18.0

cat-kun avatar Nov 01 '22 09:11 cat-kun

image 同,还没有解决方案 "@tarojs/react": "3.2.16", "@tarojs/taro": "3.2.16", "react": "^17.0.0", "taro-calendar-customizable": "^2.1.2",

midnight630 avatar Jun 08 '23 07:06 midnight630