app/helpers/lookbook/component_helper.rb in lookbook-1.0.3 vs app/helpers/lookbook/component_helper.rb in lookbook-1.0.4

- old
+ new

@@ -4,10 +4,11 @@ def icon(name, **attrs) render Lookbook::Icon::Component.new(name: name, **attrs) end - def code(**attrs, &block) + def code(language = :html, **attrs, &block) + attrs[:language] = language render Lookbook::Code::Component.new(**attrs), &block end def render_component(ref, **attrs, &block) klass = component_class(ref)