Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Focus event fire two times #379

Open
rustam87 opened this issue Aug 25, 2020 · 0 comments
Open

Focus event fire two times #379

rustam87 opened this issue Aug 25, 2020 · 0 comments

Comments

@rustam87
Copy link

Hi, your plugin the best from other autocompletes plugins. Thanks
But yesterday i found this problem
Focus event fire two times
In my case i send ajax on focus and i have 2 requests instead one

<template>
  <div>
    <h1 style="text-align: center;">Simple Example</h1>

    <p>This is the simplest example.</p>

    <b>Selected:</b> {{ selected || "not chosen" }}. <br><br>

    <cool-select @focus="onFocus" v-model="selected" :items="items" placeholder="Select name" />
  </div>
</template>

<script>
import { CoolSelect } from "vue-cool-select";

export default {
  components: {
    CoolSelect
  },
  data() {
    return {
      selected: null,
      items: ["Anton", "Andrey", "Sasha", "Vladimir", "Dima"]
    };
  },

  methods: {
    onFocus(){
      console.log('focus')
    }
  }
};
</script>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant