In my react app , I am creating a canvas element dynamically.
Now, I want to access that DOM element from ComponentDidMount lifecycle method, however, I am not able to do that.
Below is my code :
https://codesandbox.io/s/drawing-on-canvas-by-mouse-events-forked-ezrdgd
Any help will be much appreciated. Thanks