UNPKG

react-dnd

Version:

Drag and Drop for React

18 lines (17 loc) 519 B
export function registerTarget(type, target, manager) { const registry = manager.getRegistry(); const targetId = registry.addTarget(type, target); return [ targetId, ()=>registry.removeTarget(targetId) ]; } export function registerSource(type, source, manager) { const registry = manager.getRegistry(); const sourceId = registry.addSource(type, source); return [ sourceId, ()=>registry.removeSource(sourceId) ]; } //# sourceMappingURL=registration.js.map