1.1.0 • Published 5 years ago

vue-click-outside v1.1.0

Weekly downloads
64,034
License
MIT
Repository
github
Last release
5 years ago

ClickOutside

Vue click outside directive.

Installation

$ npm install vue-click-outside

Example

<template>
  <div>
    <div v-click-outside="hide" @click="toggle">Toggle</div>
    <div v-show="opened">Popup item</div>
  </div>
</template>

<script>
import ClickOutside from 'vue-click-outside'

export default {
  data () {
    return {
      opened: false
    }
  },

  methods: {
    toggle () {
      this.opened = true
    },

    hide () {
      this.opened = false
    }
  },

  mounted () {
    // prevent click outside event with popupItem.
    this.popupItem = this.$el
  },

  // do not forget this section
  directives: {
    ClickOutside
  }
}
</script>

Badges

npm.io npm.io


fundon.me  ·  GitHub @fundon  ·  Twitter @_fundon

@kubrick/kubrickuiauctic-uiverto-dashboard-packagescomponentsroi-filemanager-vuevue-dashboard-generatorac-components-dynamicibg-layout-base@nines/vuepress-theme-ninevuepress-theme-naviimidsummernight-modals@chagassiasp/scomponentvuepress-theme-idovideo-section-situoakmont-bakery-posvuepress-theme-timibrawlupbrawlup-docs@leecervan/vuepress-theme-plutovuepress-theme-roplamasign-components-librarytechlines-framework-02@infinitebrahmanuniverse/nolb-vue-clic@everything-registry/sub-chunk-3076@zekoder/zekoder-web-components@abdash/zekoder-web-componentscentral-pluswahelp-chatvue-icon-pickervue-map-3dwelchisx.uitechlines-framework-01thgy-componentsv-select-boxvb-datepickervue-bulma-custom-datepickervue-bulma-datepickervue-bulma-datepicker-jjvue-bulma-datepicker-nfervue-bulma-datepicker-ttvue-bulma-datepicker-waydotnetvue-bulma-datepicker2vue-crud-componentvue-ctevue-dashboard-buildervue-date-of-birth-multivue-aw-components@demos-europe/demosplan-ui@bytefury/spacewind@prianiki/ui@perezmarc/vuemarc-ui-kit@primitivesocial/legojobbsontableki-componentsklook-web-uikitlb-vue-floatmenulb-vue-selectstocknowuma-unimax-mesuma-unimax-webtheme-for-learningtradetime-webtradetime-web_1tradetime-webuildtoe-icons@apility/rule-builder-vue@arckinteractive/noah-ui2pv-vue-bulma-datepickeryiatatestyk_ui_kitxsqvuecomponentsvuepress-theme-ckqvuepress-theme-congvuepress-theme-copvuepress-theme-emjiovuepress-theme-fakevuepress-theme-fusevuepress-theme-haobomvuetifullvue2-ajax-autocompletevuepress-theme-sumscvuepress-theme-sqlee-blogvuepress-theme-reco-hjyvuepress-theme-reco-ldyvuepress-theme-reco-lsvuepress-theme-recodvuepress-theme-recoxvuepress-theme-plutovuekpvuepress-jarvis-recovuepress-theme-briefvuepress-theme-wirevuepress-theme-xenonvuepress-theme-yuuvuepress-theme-jabinblogvuepress-theme-navivuepress-theme-ninevuepress-theme-ldyvuepress-theme-learing
1.1.0

5 years ago

1.0.7

8 years ago

1.0.6

8 years ago

1.0.5

8 years ago

1.0.4

8 years ago

1.0.3

8 years ago

1.0.2

8 years ago

1.0.1

8 years ago

1.0.0

8 years ago

0.4.3

9 years ago

0.4.2

9 years ago

0.4.1

9 years ago

0.4.0

9 years ago

0.3.0

9 years ago

0.2.1

9 years ago

0.2.0

9 years ago

0.1.0

9 years ago