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

130
Vistas
Disable multiple component in many page in big VueJS application?

Hi everyone, thank you for supporting me about this stuff!

I have an use-case that I have 2 host run in the same project, for example : host1: "sale.app.com", host2: "hr.app.com". In my project I have many re-usable components using in many pages ( , ,...), so in case in "hr.app.com", I don't want to show those components, I want disable them in "hr.app.com"

=> First approach I can make it up is: I can check in single component with routes.name. But those components're used in many place in my app, there will be big duplication code. So I don't to use this approach. I don't want this approach like below.

<project v-if="['app.sale'].indexOf($route.name) > -1"></project>

So does you guy have any approach for my use-case. Something like vue-router machanism or something that I don't know. Please let me know if you guys have any recommendation for this use-case.

Thank you guy so so much !! 
about 4 years ago · Juan Pablo Isaza
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