want to Modify the displayBirthdate function to display a userâs age from the API call in getAUserProfile() in a DIV with a CSS
var displayBirthdate = ({dob}) => { document.querySelector('.details').textContent = dob.age + 'years old'; }; var displayAddress = ({location = 'location'}) => {}; var displayPhone = ({phone = 'phone', cell = 'cell'}) =>{}; const displayExtraUserInfo = (param) => { document.querySelector('#btn-birthdate').addEventListener('click', () => { displayBirthdate(param); }); document.querySelector('#btn-phone').addEventListener('click', () => { displayPhone(param); }); document.querySelector('#btn-address').addEventListener('click', () => { displayAddress(param); }); }; const notify = (msg) => { const toastr = document.querySelector('.messages'); if(!toastr) return; toastr.textContent = msg; if(!toastr.classList.contains('on')) { toastr.classList.add('on'); } };