Why is there a discrepancy in the height of an empty display: inline
element between Chrome and Firefox? Is this a bug or a difference in interpretation of specifications?
Moreover, how do web developers typically address this issue?
// In Chrome, logs 0; in Firefox, logs non-0.
console.log(document.querySelector('bar').getBoundingClientRect().height);
<foo>
<bar></bar>
</foo>