v147 · SVG
Support path attribute on SVG <textPath> element
The <textPath> element gains a path attribute so you can define the curve inline — no more hunting for a matching id on a hidden <path> in <defs>.
concepts
-
Inline Path Text
Side-by-side comparison of the old
<defs>-based approach versus the new inlinepathattribute. Same visual output, far less ceremony. -
Path Text Builder
Live editor: type a message and drag cubic-bezier control points — the SVG path data updates in real time and text flows along your custom curve.
-
Animated Text Path
Text flowing continuously along animated SVG paths — wave, circle, arch, zigzag, and loop shapes. Adjust font size and scroll speed, and the inline
pathattribute updates live so no<defs>rewrite is needed. -
Text on Path Generator
Choose from 6 preset path curves (wave, arch, circle, S-curve, zigzag, spiral), then dial in font size, start offset, text side, and font family. The SVG updates live using the inline
pathattribute. Side-by-side comparison with the old<defs>-based approach and an SVG export button. -
Compatibility Lab
Detects the inline
pathattribute on<textPath>via DOM inspection. Side-by-side rendering comparison of new<textPath path="…">versus the classic<textPath href="#id">approach. Provides a detection helper function and a unifiedmakeTextPath()factory that uses whichever method the browser supports.
why it shipped
SVG 1.1 required the text path to be declared as a separate <path> element — usually tucked away inside <defs> — and then referenced by ID. This two-step ceremony makes dynamic and template-generated SVG cumbersome: you need to mint a unique ID, inject the path element, and keep the href in sync. Every major browser except Chrome had already implemented the path attribute defined in SVG 2, which lets you embed the path data directly on <textPath> itself. Chrome 147 closes that interoperability gap.
references
implementation reference
Need the exact API surface, compatibility boundaries, errors, lifecycle, and source links? Read the matching gendn reference ↗