I have the following configuration file in my nodejs project
const firebase = require('firebase/app');
// Your web app's Firebase configuration
// For Firebase JS SDK v7.20.0 and later, measurementId is optional
const firebaseConfig = {
  apiKey: "AIzaSyBNMB7IdCKV7iObJDSSFTRVHp9M8ZndpZh2c",
  authDomain: "ivrs-d422d.firebaseapp.com",
  databaseURL: "https://ivrs-d422d.firebaseio.com",
  projectId: "ivrs-d422d",
  storageBucket: "ivrs-d422d.appspot.com",
  messagingSenderId: "10387822329211",
  appId: "1:1038786929211:web:6ed1a58fewqa9855105ef21e",
  measurementId: "G-ZTY9VS9EK9"
};
// Initialize Firebase
firebase.initializeApp(firebaseConfig);
const db = firebase.database();
and i get the following error:
/Users/Documents/Market/config/firebaseConfiguration.js:26
  const db = firebase.database();
                      ^
TypeError: firebase.database is not a function
    at Object.<anonymous> 
(/Users/Documents/Market/config/firebaseConfiguration.js:26:23)
Can someone explain why that is happening?