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

371
Visualizações
What is the problem, the code throws no error but it said SyntaxError: Cannot use import statement outside a module

This is the error I get :

SyntaxError: Cannot use import statement outside a module

  .on("queueEnd", (player) => {
    let QueueEmbed = new MessageEmbed()
      .setAuthor({
        name: "The queue has ended",
        iconURL: this.botconfig.IconURL,
      })
      .setColor(this.botconfig.EmbedColor)
      .setTimestamp();
      client.channels.cache
      .get(player.textChannel)
      .send({ embeds: [QueueEmbed] });
    })
      if (!this.botconfig["24/7"]) {
        setTimeout(() => {
    if (player.paused || player.playing ||  player.queue.length > 0) return;
          player.destroy();
        },2*60*1000//time in milliseconds ;-; 2 minutes
        )};
  }
about 4 years ago · Juan Pablo Isaza
1 Respostas
Responde à pergunta

0

Whenever you use the import (or export) keywords, you will need to make sure that the file containing these keywords is a module. A common way of making a mistake in this respect is to create a <script> tag in your HTML without a type="module" attribute.

Read more here: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Modules

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