I'm new to StackOverflow and coding. I want to know if it is possible to call a variable object within a variable object in JavaScript.
Maybe something like this:
var info {
name: function() {
document.write("Jordan");
last: function() {
document.write("Baron");
}
}
So when you call info.name(), it does document.write("Jordan), and when you do info.name().last(), it does document.write("Baron")
If it's a stupid question, be brutal. I want to learn from my mistakes.