Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

137
Views
Trying to implement react beatiful dnd in my project but I cant get it to work

the code looks like this :

<DragDropContext>
              <Droppable droppableId="tasklist">
                {(provided) => (
                  <ul className="tasklist" {...provided.droppableProps} ref={provided.innerRef}> 
                    {this.state.tasks.map((task, index) => (
                      <Draggable key={uuid()} draggableId={uuid()} index={index}>
                        {(provided) => (
                          <li ref={provided.innerRef} {...provided.draggableProps} {...provided.dragHandleProps}>
                            <button className='btn bg-transparent' onClick={() => this.removeTask(index)}><p key={index} className="task">{task.type || "test"} | {this.formatTime(task.time || 60)}</p></button>
                          </li>
                        )}
                      </Draggable>
                    ))}
                    {provided.placeholder}
                  </ul>
                )}
              </Droppable>
            </DragDropContext>

I followed this (https://www.freecodecamp.org/news/how-to-add-drag-and-drop-in-react-with-react-beautiful-dnd/) guide and tried to fit it to my code, anyone know what could be wrong?

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!