moveable icon indicating copy to clipboard operation
moveable copied to clipboard

Using functional components How to trigger updateTarget (React,hooks)

Open Bain-liu opened this issue 6 years ago • 2 comments

Environments

  • Framework name:
  • Framework version:
  • Moveable Component version:
  • Testable Address(optional):

Description

Bain-liu avatar Mar 21 '20 07:03 Bain-liu

@liuxuehuax

You will need to get an instance using useRef.

const moveableRect = React.useRef();

moveableRect.current.updateRect();

daybrush avatar Mar 21 '20 22:03 daybrush

The problem was solved the day before yesterday and I forgot to close the question. But thank you very much. @daybrush

Bain-liu avatar Mar 23 '20 06:03 Bain-liu