From 48c72a67337031b7e394f7ef99a3e2e532a46f0b Mon Sep 17 00:00:00 2001 From: Kate Higa <16447748+khiga8@users.noreply.github.com> Date: Tue, 3 May 2022 08:11:46 -0700 Subject: [PATCH] Update no-title-attribute-counter.md --- docs/rules/accessibility/no-title-attribute-counter.md | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/docs/rules/accessibility/no-title-attribute-counter.md b/docs/rules/accessibility/no-title-attribute-counter.md index 7ba7d79..3bab99c 100644 --- a/docs/rules/accessibility/no-title-attribute-counter.md +++ b/docs/rules/accessibility/no-title-attribute-counter.md @@ -31,10 +31,14 @@ Use a `` element instead of the `title` attribute, or an `aria-label`. ### **Correct** code for this rule 👍 ```erb -<a href="github.com" aria-describedby="description">GitHub</a> -<p id="description" class="tooltip js-tooltip">A home for all developers</p> +<a href="github.com">GitHub</a> ``` +**For [Primer ViewComponent](https://primer.style/view-components/) consumers only**: + ```erb -<a href="github.com">GitHub</a> +<%= render(Primer::LinkComponent.new(href: "github.com", id: "link-with-tooltip")) do |c| %> + <% c.tooltip(text: "A home for all developers") %> + GitHub +<% end %> ```