marcojakob / dart-dnd

Drag and Drop for Dart web apps with mouse and touch support.
https://code.makery.ch/library/dart-drag-and-drop/
MIT License
135 stars 86 forks source link

setting Draggable and Dropzone that are built with Future/Stream #28

Closed ronmany closed 6 years ago

ronmany commented 6 years ago

Hi,

How can I setup Draggable and Dropzone on a list that are made "later" by Stream or Future I try to instantiate thm in ngAfterViewInit but it does not help, by the the time I call Draggable or Dropzone the elements are not built yet.

Thank you,

marcojakob commented 6 years ago

The way the package is set up currently, you can't add elements to existing Draggables or Dropzones. But maybe you don't need to. Have you tried creating the Draggable or Dropzone in the ngAfterViewInit?