Overnap
Builds for 1 pipeline failed in 1 minute 22 seconds

clearCanvas 콜백 추가

......@@ -38,6 +38,15 @@ export const Canvas: React.FC = () => {
}
}, []);
const clearCanvas = useCallback(() => {
if (canvasRef.current) {
const context = canvasRef.current.getContext('2d');
if (context) {
context.clearRect(0, 0, canvasRef.current.width, canvasRef.current.height);
}
}
}, []);
const startPaint = useCallback((event: MouseEvent) => {
const coordinates = getCoordinates(event);
if (coordinates) {
......