Donate. I desperately need donations to survive due to my health

Get paid by answering surveys Click here

Click here to donate

Remote/Work from Home jobs

Console.log is returning different results when compared to alert

Why is it when I do a console.log on my math object I get the whole object returned but only the value when I use alert?

math.config({
  number: 'BigNumber',
  precision: 64
})

// use math
var a = math.eval('0.1 + 0.2')
console.log(a)
console.log(typeof a)

alert(a)
alert(typeof a)
<script src="https://cdnjs.cloudflare.com/ajax/libs/mathjs/5.2.3/math.min.js"></script>

Console:

console

Alert:

alert

Thank you for your help.

Comments