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

441
Visualizações
next.js video import vs reference - what is the next.js way to import videos?

I am adding a video as a background inside of the banner.

I am using next.js and usually with images I would just import them and then pass this import as src (e.g. import img from '@images/about-us-page/img.svg').

Currently when I try doing the same with mp4 video its not displaying the file inside of the files available to be imported. When I use require instead it complains that webpack needs to be configured.

What is the most performence efficent way to import videos? Would that be creating videos dir in public and then just referencing in?

Would reference public for images also be a better solution than importing images?

regards

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