Skip to content

Commit b23640b

Browse files
committed
fix flake
1 parent 9cedaec commit b23640b

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

‎lib/view_component/engine.rb‎

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,11 @@ class Engine < Rails::Engine # :nodoc:
8181
ActiveSupport.on_load(:after_initialize) do
8282
if Rails.application.config.eager_load
8383
ActiveSupport::Notifications.instrument("compile.view_component") do
84-
ViewComponent::Base.descendants.each(&:__vc_compile)
84+
ViewComponent::Base.descendants.each do |component|
85+
next unless component.name
86+
87+
component.__vc_compile
88+
end
8589
end
8690
end
8791
end

0 commit comments

Comments
 (0)