JavaScript learning function type

Source: Internet
Author: User

1. Functions are objects, as well as properties and methods. Because a function is an object, the function name is actually a pointer to a function object and is not bound to a function.

2. Using the function name without parentheses is to access the function pointer, not the calling function.

3. Because the function name in ECMAScript itself is a variable, the function can also be used as a value.

4. Inside the function, there are two special objects: arguments and this, where arguments is a class array object that contains all the parameters passed into the function. Arguments also has a callee property, which is a pointer to the function that owns the arguments object.

5. Each function consists of two properties: length and prototype. Where length indicates the number of named arguments that the function expects to receive. Prototype are the real place where all of their instance methods are saved.

JavaScript learning function type

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.