react-checkbox-tree icon indicating copy to clipboard operation
react-checkbox-tree copied to clipboard

Uncaught TypeError: e[n].forEach is not a function

Open Clementol opened this issue 4 years ago • 4 comments

Uncaught TypeError: e[n].forEach is not a function The main tree is working but to show the children is the problem following the example at npm website

Expected to show sub tree I expected drop down to show

Clementol avatar Dec 29 '20 21:12 Clementol

Im getting the same issue, but someone on my team has it working. Copying his code doesnt resolve my issue

WBucci avatar Jan 19 '21 16:01 WBucci

Can you link to a live version which shows this issue, using this CodeSandbox reference point as a base?

jakezatecky avatar Jan 20 '21 00:01 jakezatecky

i got this issue when i use hooks in checked and expanded: checked => setChecked( { checked }). remove "{" and "}" work for me : checked => setChecked( checked ).

glxdsunname avatar Feb 26 '21 07:02 glxdsunname

That is possible error others may be experiencing. The checked, expanded, and nodes property should all be Arrays.

jakezatecky avatar Mar 05 '21 15:03 jakezatecky

Since the docs all reference functional/hook usage now, this should no longer be confusing to developers without class experience.

jakezatecky avatar Mar 21 '23 23:03 jakezatecky