From a75b25333d94bef710bbc05a95baa2e77b61bca9 Mon Sep 17 00:00:00 2001 From: Amr Ojjeh Date: Wed, 19 Jun 2024 03:40:13 -0500 Subject: Add dir (#176) `dir` is a global attribute that lets you specify whether text is RTL or LTR or if it should be determined by the browser. Documentation: https://developer.mozilla.org/en-US/docs/Web/HTML/Global_attributes/dir--- html/attributes.go | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'html/attributes.go') diff --git a/html/attributes.go b/html/attributes.go index 728807b..98d70ff 100644 --- a/html/attributes.go +++ b/html/attributes.go @@ -270,3 +270,7 @@ func Width(v string) g.Node { func EncType(v string) g.Node { return g.Attr("enctype", v) } + +func Dir(v string) g.Node { + return g.Attr("dir", v) +} -- cgit 1.4.1