Skip to content
Related Articles
Get the best out of our app
GeeksforGeeks App
Open App
geeksforgeeks
Browser
Continue

Related Articles

SVG DOMStringList.length Property

Improve Article
Save Article
Like Article
Improve Article
Save Article
Like Article

The SVG DOMStringList.length property returns the length of the given DOMStringList element.

Syntax:

len= DOMStringList.Length

Return value: This property returns the length of the DOMStringList.

Example 1: 

HTML




<!DOCTYPE html> 
<html
  
<body
    <svg width="350" height="350" 
        xmlns="http://www.w3.org/2000/svg">
  
        <script>
            var a=["gfg","a","c","eg"];
            console.log(a.length)
        </script>
    </svg>
</body
  
</html

Output:

Example 2: 

HTML




<!DOCTYPE html> 
<html
  
<body
    <svg width="350" height="350" 
        xmlns="http://www.w3.org/2000/svg">
  
        <script>
            var a=[1,2,4,56];
            console.log(a.length)
        </script>
    </svg>
</body
  
</html>

Output:


My Personal Notes arrow_drop_up
Last Updated : 30 Mar, 2022
Like Article
Save Article
Similar Reads
Related Tutorials