Create angular drag and drop component using angular material api
Follow the below steps to build drag and drop component:- ng add @angular/cli ng new fms ng add @angular/material ng add @angular/cdk ng generate @angular/cdk:drag-drop draganddrop draganddrop.component.html < div class = "container" > < h2 >To do</ h2 > < div cdkDropList #todoList = "cdkDropList" [cdkDropListData] = "todo" [cdkDropListConnectedTo] = "doneList" class = "list" (cdkDropListDropped) = "drop($event)" > < div class = "list-item" *ngFor = "let item of todo" cdkDrag >{{item}}</ div > </ div > </ div > < div class = "container" > < h2 >Done</ h2 > < div cdkDropList #doneList = "cdkDropList" [cdkDropListData] = "done" [cdkDropListConnectedTo] = "todoList" class = "list" (cdkDropListDropped)