Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

294
Views
Mensaje de error de la consola Firebase.database() no es una función

Estoy tratando de implementar una cuenta regresiva del lado del servidor con firebase con la función TIMESTAMP, sin embargo, a pesar de seguir la documentación proporcionada por firebase y también una publicación sobre esto hace un tiempo ( Cómo implementar un temporizador de cuenta regresiva distribuido en Firebase ), la consola sigue diciendo yo que firebase.database() no es una función:

 // Import the functions you need from the SDKs you need import { initializeApp} from "https://www.gstatic.com/firebasejs/9.8.1/firebase-app.js"; import { getDatabase, ref, onValue, update, get, set} from "https://www.gstatic.com/firebasejs/9.8.1/firebase-database.js"; // TODO: Add SDKs for Firebase products that you want to use // https://firebase.google.com/docs/web/setup#available-libraries // Your web app's Firebase configuration const firebaseConfig = { apiKey: "AIzaSyDZY8ufwFMkPhzOY-dNJm9bGXqv9okoW5g", authDomain: "f1-crypto.firebaseapp.com", databaseURL: "https://f1-crypto-default-rtdb.asia-southeast1.firebasedatabase.app", projectId: "f1-crypto", storageBucket: "f1-crypto.appspot.com", messagingSenderId: "512980395232", appId: "1:512980395232:web:9d81bc5d7c58bc5a13dc85" }; // Initialize Firebase const firebase = initializeApp(firebaseConfig); const database = firebase.database(); const reff = database.ref("countdown"); reff.set({ startAt: ServerValue.TIMESTAMP, seconds: 20 });
 Uncaught TypeError: firebase.database is not a function

La documentación para esta cuenta regresiva de marca de tiempo también es bastante escasa, por lo que cualquier ayuda sería muy apreciada.

about 4 years ago · Juan Pablo Isaza
1 answers
Answer question

0

const database = getDatabase();

¿Has probado esto?

about 4 years ago · Juan Pablo Isaza Report
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!