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

138
Vistas
Is there a way to execute rest of the script after performing window.location change?

Working on small chrome extension using manifest v3. Basically I have a line in my code that changes the window location to another page (it is required). The following line is supposed to find the element once the window has changed.

abstract:

window.location = "link to other web"
const element = document.querySelector("div")
console.log(element)

The problem is of course the fact that lines after window.location doesn't work because they do not exist anymore. Is there a way to keep the logic after the refresh/reload?

Perfectly if it would work like selenium (in brower, not in window). As mentioned I'm using manifest v3 api so maybe there is a way to keep the code...

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