Compare Revisions

Function.name

Revision 1046:

Revision 1046 by Seant23 on

Revision 1047:

Revision 1047 by Andrea@3site.it on

Title:
name
name
Slug:
JavaScript/Reference/Global_Objects/Function/name
JavaScript/Reference/Global_Objects/Function/name
Tags:
NeedsJSVersion
NeedsJSVersion
Content:

Revision 1046
Revision 1047
tt79    <p>
80      You cannot define a cutom function name because this parame
 >ter is read only.
81    </p>
82    <pre class="eval">
83var object = {
84  // anonymous
85  someMethod: function (){}
86};
87object.someMethod.name = "someMethod";
88alert(object.someMethod.name); // empty string, someMethod is ano
 >nymous
89</pre>

Back to History