Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

360
Vistas
This expression is not callable. Type 'Boolean' has no call signatures. Error in Vue3 computed property

I am trying to create a computed property where it checks item is in the array. So i created this function that returns boolean value and takes one parameter which is the item i will check.

isSelected: function (item: MediaGalleryItemTypes) {
  return this.selectedItems.some(e => e._id === item._id)
}

In the template section i have to send the variable to another component, here is how i use it

 DocumentCard(:is-selected="isSelected(document)")

The code gives error as

chunk-common.js:5918 Uncaught (in promise) TypeError: _ctx.isSelected is not a function

and in vscode it gives the error as:

This expression is not callable. Type 'Boolean' has no call signatures.

How can i fix this and make a computed property to get a parameter?

about 4 years ago · Santiago Gelvez
1 Respuestas
Responde la pregunta

0

You can't pass parameters to computed properties (unless the computed return a function). You can use with the standard method

Can I pass parameters in computed properties in Vue.Js

about 4 years ago · Santiago Gelvez Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda