Skip to content

Typescript error with wrapper.find('select').element.value #1870

Closed
@Mnigos

Description

@Mnigos

Hello, I'm using typescript and got error
Property 'value' does not exist on type 'HTMLElement'.ts(2339) any
Here is my test

  it('Should write a login', async () => {
    const wrapper = shallowMount(LoginForm)
    const input = wrapper.find( '[data-test="nameOrEmailInput"]')
    await input.setValue('User123')

    expect(wrapper.find('input#input-20').element.value).toBe('User123')
  })

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions