Onready Function

Just try to think the logical way. What does the ERROR wants to tell you?

  1. You have a —> NUMBER!
  2. But expected is a —> STRING!

Conclusion? —> You will need to converst from → NUMBER → to → STRING.

How to do it?

var myNumber = 100
var myString = String(myNumber)

…or…

var myString = myNumber.toString()

This should fix your problem.