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

129
Visualizações
How can I make a screen swipe to next after a specific time in Ionic?

I have 4 screens for home screen. i want the first screen to just automatically swipe to the next after 2sec, and the remaining screens to be swipable. i used swiper for the screens but i cant figure out how to make the first screen swipe to the next after a given time. im very new to programming and new to ionic as well. my code goes like this. i put settimeout to call slidenext after 1000ms inside ngoninit so that it will function upon it loads

export class HomePage {
  config: SwiperOptions = {
    spaceBetween: 50,
    pagination: { clickable: true},
  };
  @ViewChild('swiper', { static: false }) swiper?: SwiperComponent;
    slideNext(){
      this.swiper.swiperRef.slideNext(1000);
    }
  constructor() {}
  ngOnInit() {
    setTimeout(() => {this.slideNext(), 1000})
  }
}
about 4 years ago · Juan Pablo Isaza
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