Use keyword arguments in tag methods
The interface of this method has changed and uses keyword arguments instead of a hash of options. This change will be particularly significant when upgrading to Ruby 3.
This commit is contained in:
@@ -18,7 +18,7 @@ class Shared::LinkListComponent < ApplicationComponent
|
||||
|
||||
def list_items
|
||||
present_links.map do |text, url, current = false, **link_options|
|
||||
tag.li(({ "aria-current": true } if current)) do
|
||||
tag.li("aria-current": (true if current)) do
|
||||
if url
|
||||
link_to text, url, link_options
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user