Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

148
Visualizações
Dynamically select the element from the list of elements based on child index

I need to fetch the field/element on the form for my automation code dynamically. There are multiple fields on the form and based on some particular index that is dynamic I want to fetch that element.

Thus how can I pass this column child index dynamically to the helper method to fetch the desired dynamic fields?

Selector list looks like below:

I tried something like this which does not work:

'ul li:nth-child(${index}'

Throw following error:

invalid selector: An invalid or illegal selector was specified

about 4 years ago · Juan Pablo Isaza
1 Respostas
Responde à pergunta

0

I just need to use Template Literals around the selector instead of single quotes.

`ul li:nth-child(${index})`

about 4 years ago · Juan Pablo Isaza Relatório
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda