Skip to main content
0 votes
1 answer
41 views

Composable reactivity within a mix of options and composition APIs

"vue": "^2.7.16" "nuxt": "^2.18.1" "@nuxt/bridge": "^3.3.1" I have a composable that is using Composition api. import { ref, reactive, } ...
Sambuxc's user avatar
  • 513
0 votes
1 answer
85 views

vue 3 options api data accessibility

Is there a manner to access a vue option api. assume the below code. import {visualization} from "../util/Visualization" export default { data:() =>({ foo = '' ...
vuejscoder's user avatar
1 vote
1 answer
33 views

V-If elements displaying regardless of condition resolving to false

The issue I am facing is that my v-if elements are displaying regardless of whether their value resolves to null, 'null', false, or falsy. Here is a minimal reproducible example: JS Fiddle <...
Adequately Lost's user avatar
1 vote
0 answers
107 views

Problem with reactivity of pinia getters in imported npm package (vue 2.7)

Vue 2.7.14 (options api) Pinia 2.1.7 I have ChildApp where in "standalone" mode I normally use pinia after initializing it in main.js and everything works. Below is my store initialization....
Threshu's user avatar
  • 23
0 votes
1 answer
154 views

(Vue3) Link form component object with parent object using v-model and Options API?

My question is simple. I am following the official Vue documentation explaining v-model arguments in relation to forms in a child component. Here's my code: (App.Vue) <script> import UserName ...
Tony Moritz's user avatar
0 votes
0 answers
224 views

Prop with default value gets undefined type in Vue 2

I have a child component with code: export default { props: { search: { type: String, default: () => null, }, } } And a parent component with code: <template> <ChildComponent ...
blackkk68's user avatar
1 vote
2 answers
2k views

Use a Vue service outside of a Vue component

I'm currently working on a vue 3 app using primevue 3.46. I'm wondering if it possible to use the ToastService to display a toast outside of a vue component. Here is an example. I created an Axios ...
MrAnyx's user avatar
  • 256
0 votes
1 answer
213 views

Update model value doesn't work correctly

I'm using v-model to connect two components. I'm trying to pass value to father components and first gave me undefined. I changed code like second and that worked. My question is this: why does not ...
Mustafo Yakubov's user avatar
1 vote
1 answer
89 views

Components import error - Vue 2 with TypeScript - VS Code

has anyone had problems with TS pointing errors on custom components beeing imported to the .vue file - using the options api and webpack. Basicly the import works fine, everything is visible and ...
ciulany's user avatar
  • 23
-2 votes
1 answer
37 views

Difference between calling watcher with parentheses vs without

In watch property, what is the difference between calling property using () and not using them? export default { watch: { // syntax with () test() { if (this.test) { //some ...
bohi tibuti's user avatar
1 vote
0 answers
95 views

Vuejs Options API function import: Gives uncaught (in promise) typeerror: _ctx.functionName is not a function

Suppose I have a function named formatStr in global.js file: export const formatStr = () => { return 'something'; } Now, I am importing it a component say OptionComponent.vue: import { formatStr }...
Antor's user avatar
  • 11
0 votes
1 answer
88 views

vue.js @emit is not picked up by parent

In my app I have a form, in the ManageCards component, that conatins a child component ImageUpload, that emits and imagefile and its local URL to the parent: <form class="mb-3" > &...
M.Koops's user avatar
  • 155
1 vote
0 answers
144 views

How to use LWmsTileLayer?

I have a question about vue-leaflet (Vue 3). I'm trying to use LWmsTileLayer component. Unfortunately, this component doesn't seem to work at all. No matter what I do, all I see is a gray background. (...
DaBler's user avatar
  • 2,862
0 votes
2 answers
210 views

lazy watcher does not execute

I am new vuejs.as shown in the below posted code, the isBtnDigitizePolygonClicked is a reactive variable.i am trying to execute some lines of code as a side effect to the change of the value of ...
Amrmsmb's user avatar
  • 11.5k
0 votes
0 answers
378 views

How to update a reactive object with Vue3 (options API)

Currently I'm migrating my Vue2 project to Vue3. Here is an example that I had before and can not understand how to make it work in Vue3. <template> <div> <q-form @submit="...
cooperok's user avatar
  • 4,267

15 30 50 per page