Giter Site home page Giter Site logo

Comments (8)

generesque avatar generesque commented on June 7, 2024 1

I can confirm my use case is fixed as well. Thank you so much for the speedy resolution.

from angular-skyhook.

cormacrelf avatar cormacrelf commented on June 7, 2024

Yep, you're running an ancient react-dnd-html5-backend. You don't get peerDependencies warnings on StackBlitz. Upgrade it to v9 and it works. (Don't click the upgrade all button, that lifts core-js to v3 which apparently breaks everything again -- just enter react-dnd-html5-backend in the 'add dependency' box.)

from angular-skyhook.

generesque avatar generesque commented on June 7, 2024

I was actually just testing different package combinations to see if I could find something that works. The stackblitz is back to what my project is:

"@angular-skyhook/core": "^1.3.0",
"react-dnd-html5-backend": "^9.4.0",

This combination does not work at all. The only working combination I could find was indeed ancient:
"@angular-skyhook/core": "^1.0.11",
"react-dnd-html5-backend": "^5.0.1",

Maybe there was a recent change to react-dnd-html5-backend that broke something?

from angular-skyhook.

cormacrelf avatar cormacrelf commented on June 7, 2024

It's actually very weird, I got the StackBlitz to work exactly once and then it stopped.

from angular-skyhook.

generesque avatar generesque commented on June 7, 2024

Ok, I've done some more testing, and it seems that @angular-skyhook/core 1.3.0 or greater does not work at all with react-dnd-html5-backend 9.0.0 or greater. @angular-skyhook/core 1.2.1 works with all react-dnd-html5-backend 9.x.x versions.

from angular-skyhook.

generesque avatar generesque commented on June 7, 2024

Works: https://stackblitz.com/edit/angular-ljqvgb?file=package.json
Broken: https://stackblitz.com/edit/angular-h32cv8?file=package.json

I am unblocked at least because I can just downgrade to 1.2.1. Let me know if there's anything else I can do to help debug

from angular-skyhook.

cormacrelf avatar cormacrelf commented on June 7, 2024

I figured it out. dnd-core has, at some point, changed the way global context is provided. It used to be that { window: window } worked, but now apparently you need to pass just a plain window object. I cannot find this in any release notes, so I don't know when it broke. It also explains why the examples app with the multi-backend was fine -- it was relying on dnd-multi-backend to provide the context which didn't pass a context at all, so presumably HTML5Backend used its own defaults and survived the breaking change.

from angular-skyhook.

cormacrelf avatar cormacrelf commented on June 7, 2024

fixed in 1.3.3 https://stackblitz.com/edit/angular-syurf7

from angular-skyhook.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.