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

215
Vistas
How to use multiple methods in JavaScript at the same time

I have an input where you can search for a specific course by its name, for this I use filtering, and also the includes() method, my problem is that I need to apply three methods at the same time, the first method is toLowerCase(), the second is toUpperCase() and the last method is trim()

GetMyCourses() {
  return this.courses.filter(value => {
    return value.title.toLowerCase().includes(this.result);
  });
},

If you leave the toLowerCase method, then it does not give capital names when searching, and vice versa, in addition, if you remove these two methods, then when searching you will need to accurately search for the word

over 4 years ago · Santiago Trujillo
1 Respuestas
Responde la pregunta

0

Convert this.result to lower case as well.

GetMyCourses() {
  let result = this.result.toLowerCase()
  return this.courses.filter(value => {
    return value.title.toLowerCase().includes(result);
  });
},
over 4 years ago · Santiago Trujillo 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