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

this.$set is not a function #81

Open
umang-gramener opened this issue Dec 4, 2021 · 4 comments
Open

this.$set is not a function #81

umang-gramener opened this issue Dec 4, 2021 · 4 comments

Comments

@umang-gramener
Copy link

umang-gramener commented Dec 4, 2021

I was trying to implement this in my Vue app and I was facing this error.

Vue Version: 3

code

`< vue-multi-select
v-model="values1"
search
:options="options1"
:selectOptions="data1" />

<script> import vueMultiSelect from 'vue-multi-select'; import 'vue-multi-select/dist/lib/vue-multi-select.css'; export default { name: "FleetTab1", components: { vueMultiSelect }, data() { return { values1: [ { label: '2' }, { label: '3' }, ], data1: [{ title: 'part one', elements: [ { label: '0', disabled: true }, { label: '2' }, { label: '3' }, { label: '8' }, { label: '9' }, { label: '11' }, { label: '13' }, { label: '14' }, { label: '15' }, { label: '18' }, ], }, { title: 'part two', elements: [ { label: '23' }, { label: '25' }, { label: '31' }, { label: '42' }, { label: '56' }, { label: '76' }, { label: '82' }, { label: '42' }, { label: '13' }, { label: '21' }, ], }], options1: { multi: true, groups: true, labelName: 'label', labelList: 'elements', groupName: 'title', cssSelected: option => (option.selected ? { 'background-color': '#5764c6' } : ''), }, } } </script>`
@umang-gramener
Copy link
Author

Stack trace

vue-multi-select.common.js?dcc6:3799 Uncaught (in promise) TypeError: this.$set is not a function
at Proxy.initValues (vue-multi-select.common.js?dcc6:3799)
at Proxy.init (vue-multi-select.common.js?dcc6:3789)
at Proxy.setConfig (vue-multi-select.common.js?dcc6:3765)
at Proxy.created (vue-multi-select.common.js?dcc6:3733)
at callWithErrorHandling (runtime-core.esm-bundler.js?5c40:154)
at callWithAsyncErrorHandling (runtime-core.esm-bundler.js?5c40:163)
at callSyncHook (runtime-core.esm-bundler.js?5c40:5957)
at applyOptions (runtime-core.esm-bundler.js?5c40:5888)
at finishComponentSetup (runtime-core.esm-bundler.js?5c40:6574)
at setupStatefulComponent (runtime-core.esm-bundler.js?5c40:6505)

@iNeoO
Copy link
Owner

iNeoO commented Dec 4, 2021

Hi, this component is vue2 only sry

@umang-gramener
Copy link
Author

Hi, this component is vue2 only sry

hey, ohh okayy. is there any library you are aware of doing all these things like select and deselect all for vue 3, i tried vue multiselect and also tried their slots but cant get reactive buttons and the dropdown closes

@iNeoO
Copy link
Owner

iNeoO commented Dec 4, 2021

i didn t use any lib for vue3 atm sry

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

2 participants