Skip to content

hypercomponent class not inheriting correctly #60

Closed
@catmando

Description

@catmando

This spec fails:

  it "can create an inherited component's  insert_element alias" do
    mount 'Tester' do
      module Container
        class Base < HyperComponent
          before_mount do
            @_instance_data = []
          end
        end
        class Thing < Base
          before_mount do
            @_instance_data << "works!"
          end
          render { @_instance_data.join(" ") }
        end
      end
      class Tester < HyperComponent
        render { Container::Thing() }
      end
    end
    expect(page).to have_content('works!')
  end

No method Thing for Container!

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions