Type MethodMethodattribute(_:
attribute(_:of:)
Returns the value of an attribute of the opening tag of an SVG element.
static func attribute(
_ name: String,
of svg: String
) -> String?Parameters
nameThe attribute name.
svgThe SVG element.
Return Value
The attribute’s value, or nil if the opening tag lacks it.