Answer the question
In order to leave comments, you need to log in
Why doesn't the object method work?
Hello.
I ran into a problem: the method of the object is not executed.
var dialog = {
show : function(text) {
//тут что-то делается
},
hide : function() {
//и тут тоже
}
}
dialog.show("текст")
, everything works. dialog.hide()
get something like this:TypeError: dialog.hide is not a function
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question