@kkdev92/vscode-ext-kit - v4.1.1
    Preparing search index...

    Type Alias TreeDragAndDropOptions<T>

    TreeDragAndDropOptions: TreeDragAndDrop<T>

    Declares drag-and-drop for a tree view.

    Handed to module.treeViews.add as options.dragAndDrop; the adapter builds the platform's controller from it. Only ids cross the drag, because ids are what reliably survive its serialisation.

    Type Parameters

    module.treeViews.add({
    id: 'myext.files',
    resolveProvider: () => provider,
    options: {
    dragAndDrop: {
    mimeType: 'application/vnd.code.tree.myextfiles',
    onDrop(sourceIds, target) {
    for (const id of sourceIds) {
    const item = provider.findItem(id);
    if (item) {
    provider.removeItem(id);
    provider.addItem(item, target?.id);
    }
    }
    },
    },
    },
    });