Skip to content

Property 'select' does not exist on type 'Multiselect' #287

@cnakh

Description

@cnakh

I use with Vue 3 with TypeScript as code below

<template>
    <Multiselect
          valueProp="id"
          label="name"
          :options="getCategories"
          :searchable="true"
          ref="selectCategory"
    />
</template>

<script setup lang="ts">
import Multiselect from "@vueform/multiselect";
...
const selectCategory = ref<InstanceType<typeof Multiselect>>();
...
</script>

When I call select method it work fine in development, but when I build it get error

selectCategory.value.select(data);
Property 'select' does not exist on type 'Multiselect'.

Metadata

Metadata

Assignees

No one assigned

    Labels

    tsTypescript related issueupcoming

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions