Skip to content
New issue

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

Uncaught TypeError: Cannot read property 'parentNode' of null #680

Open
PFight opened this issue Jul 29, 2021 · 6 comments
Open

Uncaught TypeError: Cannot read property 'parentNode' of null #680

PFight opened this issue Jul 29, 2021 · 6 comments

Comments

@PFight
Copy link

PFight commented Jul 29, 2021

Please only use GitHub issues for bug reports and feature requests.

  • Read the contributing guidelines
  • Bug reports containing repro steps are likely to be fixed faster
  • Feature requests should be multi-purpose, describe use cases
  • For support requests or questions, please refer to our Slack channel

In some cases during drag occurs next error inside dragula:

    dragula.js:563 Uncaught TypeError: Cannot read property 'parentNode' of null
        at getParent (dragula.js:563)
        at getImmediateChild (dragula.js:449)
        at HTMLHtmlElement.drag (dragula.js:388)

image

image

Situation occurs because of target is removed from DOM during the drag (it's custom reaction of drag container to drag over). It's needed to add null check there.

"dragula": "^3.7.3",
"react-dragula": "^1.1.17",

@PFight
Copy link
Author

PFight commented Sep 3, 2021

Also occurs during drag over page, when some element removed from the DOM while dragging over it.

@PFight
Copy link
Author

PFight commented Sep 13, 2021

Fixed in temporary package dragula-fixed

@ignaciostellino
Copy link

@PFight do you think that you can also add this fix #529 in your package dragula-fixed ?

@PFight
Copy link
Author

PFight commented Dec 9, 2022

@PFight do you think that you can also add this fix #529 in your package dragula-fixed ?

Ok, you can make pull request to speed up process.

@ignaciostellino
Copy link

ignaciostellino commented Dec 14, 2022

Ok, you can make pull request to speed up process.

@PFight Here you have PFight#1

@PFight
Copy link
Author

PFight commented Dec 14, 2022

Ok, you can make pull request to speed up process.

@PFight Here you have PFight#1

Here you go [email protected]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants