VOOZH about

URL: https://www.geeksforgeeks.org/html/svg-event-returnvalue-property-2/

⇱ SVG Event.returnValue Property - GeeksforGeeks


  • Courses
  • Tutorials
  • Interview Prep

SVG Event.returnValue Property

Last Updated : 23 Jul, 2025

The SVG Event.returnValue property indicates whether the default action for this event has been prevented or not.

Syntax:

var bool = event.returnValue

Return value: This property returns the boolean value of the event element.

Example 1: In this example, we will use onclick event for the SVG circle element.

Output:

👁 Image

Example 2:In this example, we will use the onclick event for the SVG text element.

Output:

👁 Image

Example 3: In this example, we will use onmouseover event for the SVG circle element.

Output:

👁 Image

Example 4: In this example, we will use onmouseover event for the SVG text element.

Output:

👁 Image
Comment