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

324
Visualizações
Firebase Chrome extension generating error

enter image description here

the code in the HTML file is:

<script src="https://www.gstatic.com/firebasejs/9.1.2/firebase-app.js"></script>
<script src="https://www.gstatic.com/firebasejs/9.1.2/firebase-database.js"></script>
<script src="firebase.js"></script> 

And the firebase.js has this code:

  // Import the functions you need from the SDKs you need
  // import { initializeApp } from "https://www.gstatic.com/firebasejs/9.1.2/firebase-app.js";
  // TODO: Add SDKs for Firebase products that you want to use
  // https://firebase.google.com/docs/web/setup#available-libraries

function initializeApp() {
  // Your web app's Firebase configuration
  const firebaseConfig = {
    apiKey: "XXXXXXXXXXXXXXXXXXXXX",
    authDomain: "coupon-finder-73300.firebaseapp.com",
    projectId: "coupon-finder-73300",
    storageBucket: "coupon-finder-73300.appspot.com",
    messagingSenderId: "432596469035",
    appId: "1:432596469035:web:54b907640f9065fc33b16e"
  };

  // Initialize Firebase
  const app = initializeApp(firebaseConfig);
  console.log(app);  
}

The folder is load unpacked in the chrome extension, and there it generates no error, but as shared in the image above when I browse that file in the browser it generates an error:

Uncaught SyntaxError: Unexpected token 'export'
firebase-database.js:1 Uncaught SyntaxError: Cannot use import statement outside a module

what step should I do to troubleshoot?

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