@atlaskit/pragmatic-drag-and-drop-react-beautiful-dnd-migration
Version:
An optional Pragmatic drag and drop package that enables rapid migration from react-beautiful-dnd to Pragmatic drag and drop
16 lines (15 loc) • 391 B
TypeScript
/**
* This type is not exported by `@atlaskit/pragmatic-drag-and-drop`
*/
export type DragSource = {
element: HTMLElement;
dragHandle: Element | null;
data: Record<string, unknown>;
};
export type Action<Name extends string, Payload = undefined> = Payload extends undefined ? {
type: Name;
} : {
type: Name;
payload: Payload;
};
export type CleanupFn = () => void;