Mi objetivo es poder recuperar los valores totales presentes en una base de datos en tiempo real en Firebase a través de Javascript. Tengo todo configurado y funcionando perfectamente, pero no tan bien como para obtener los valores totales presentes cuando hago clic en un simple botón.
Este es un ejemplo de los valores que me gustaría poder tomar: 
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Document</title> </head> <body> <button type="submit" id="searchData" class="btn btn-primary">Search data</button> </body> </html> <script type="module"> import { initializeApp } from "https://www.gstatic.com/firebasejs/9.6.8/firebase-app.js"; import { getDatabase, set, ref ,push, child, onValue} from "https://www.gstatic.com/firebasejs/9.6.8/firebase-database.js"; const firebaseConfig = { apiKey: "********************************", authDomain: "********************************", databaseURL: "********************************", projectId: "********************************", storageBucket: "****************************", messagingSenderId: "******************", appId: "********************************" }; const app = initializeApp(firebaseConfig); const db = getDatabase(app); searchData.addEventListener('click',(e) => { // }); </script>