Repository navigation
Closed
Labels
Description
Bug Report
Ionic Info
Run ionic info from a terminal/cmd prompt and paste the output below.
Beta.16
Describe the Bug
Sometimes I get this error:
reorder node not found
ReorderGroup.canStart | @ | ej7i9is4.entry.js?db64:107
-- | -- | --
| canStart | @ | ej7i9is4.entry.js?db64:82
| pointerDown | @ | gesture.js?a52d:246
| handleMouseDown | @ | gesture.js?a52d:69
And on doing drag/drop I get this
Uncaught TypeError: reorderGroup.complete is not a function
at VueComponent.reorderedsss (RouteForm.js?e195:218)
at invoker (vue.runtime.esm.js?2b0e:2023)
at HTMLElement.fn._withTask.fn._withTask (vue.runtime.esm.js?2b0e:1822)
at Object.Hn (ionic.core.js?1390:6)
at Object.t.emit [as vn] (ionic.core.js?1390:6)
at Object.emit (ionic.core.js?1390:6)
at ReorderGroup.onEnd (ej7i9is4.entry.js?db64:201)
at onEnd (ej7i9is4.entry.js?db64:85)
at pointerUp (gesture.js?a52d:332)
at HTMLDocument.handleMouseUp (gesture.js?a52d:88)
Steps to Reproduce
I have ion-reorder-group list in modal.
Related Code
In HTML
<ion-list>
<ion-reorder-group @ionItemReorder="reorderedEvent" disabled="false">
<ion-item>
<ion-label>
Item 1
</ion-label>
<ion-reorder slot="end"></ion-reorder>
</ion-item>
<ion-item>
<ion-label>
Item 2 (default ion-reorder slot="start")
</ion-label>
<ion-reorder slot="start"></ion-reorder>
</ion-item>
</ion-reorder-group>
</ion-list>
In VueJs component I have method.
reorderedEvent(detail) {
const reorderGroup = document.querySelector("ion-reorder-group");
reorderGroup.complete();
},
I have tried both .complete() with ion-reorder-group element selector and even (detail) parameter but for both I get
RouteForm.js?e195:218 Uncaught TypeError: reorderGroup.complete is not a function
at VueComponent.reorderedsss (RouteForm.js?e195:218)
at invoker (vue.runtime.esm.js?2b0e:2023)
at HTMLElement.fn._withTask.fn._withTask (vue.runtime.esm.js?2b0e:1822)
at Object.Hn (ionic.core.js?1390:6)
at Object.t.emit [as vn] (ionic.core.js?1390:6)
at Object.emit (ionic.core.js?1390:6)
at ReorderGroup.onEnd (ej7i9is4.entry.js?db64:201)
at onEnd (ej7i9is4.entry.js?db64:85)
at pointerUp (gesture.js?a52d:332)
at HTMLDocument.handleMouseUp (gesture.js?a52d:88)
Expected Behavior
A clear and concise description of what you expected to happen.
Additional Context
List any other information that is relevant to your issue. Stack traces, related issues, suggestions on how to fix, Stack Overflow links, forum links, screenshots, OS if applicable, etc.
Metadata
Metadata
Assignees
Labels
Type
Fields
No fields configured for issues without a type.
Activity
[-]Ionic beta.15 reorder list throws error. Using Ionic 4 with VueJs[/-][+]Ionic beta.16 reorder list throws error. Using Ionic 4 with VueJs[/+]stripathix commentedon Nov 23, 2018
Hi @manucorporat, Please could look into this if I am doing anything wrong or ionic have a bug related to reorder list?
I am using reorder list in modal.
manucorporat commentedon Nov 28, 2018
can you debug it further? what is detail? it might be the event itself
high1 commentedon Dec 6, 2018
This issue is not exclusive to Vue, same thing happens on @ionic/angular. Reorder node not found and list is frozen. Calling complete on ev.detail.complete() does not work. Same behaviour can be seen on the sample reorder page on beta documentation site.
3 remaining items
anish714 commentedon Dec 21, 2018
@stripathix, you have to call ev.detail.complete(); inside your ionItemReorder event.
daem0ndev commentedon Dec 26, 2018
I am also seeing this issue with a slight caveat... after doing ev.detail.complete() in the ionItemReorder handler, it stopped the error on the first time, but if i close and reopen the page again then it throws the reorder node not found error as soon as I click one of the reorder handles.
(this is on ionic/angular btw)
david0178418 commentedon Dec 28, 2018
Can confirm the same behavior in rc0 w/ angular described by @daem0ndev . I can resort lists the first time I navigate to a page, but if I navigate away and return, I get the following.
david0178418 commentedon Dec 28, 2018
Quick addendum. I was so focused on trying to figure out the bug, I just realized that it seems to be benign. The reorder works as well as the event handler.
high1 commentedon Jan 8, 2019
I could not reproduce this with rc0 - reorder is working.
IsaacSomething commentedon Jan 20, 2019
Im getting this issue on
"@ionic/angular": "^4.0.0-rc.2",i have pretty basic setup with the order items in a
*ngForhigh1 commentedon Jan 20, 2019
You must call event.detail.complete() in reorder function. Reordering works, there still an issue with reorder node not found in console, but it does not break the functionality.
fix(gesture): destroy gesture handler when it's done
fix(gesture): destroy gesture handler when it's done (#17184)
IsaacSomething commentedon Jan 21, 2019
I dont think this issue should be closed. Yes as @high1 pointed out, it does break the reorder functionality but there is still a console error.
manucorporat commentedon Jan 21, 2019
The underlining issue has been fixed in the PR above
59bd823
ionitron-bot commentedon Feb 20, 2019
Thanks for the issue! This issue is being locked to prevent comments that are not relevant to the original issue. If this is still an issue with the latest version of Ionic, please create a new issue and ensure the template is fully filled out.