0
object properties and methods in javascript
what is the difference between the use of object properties and object method in javascript?
1 Answer
+ 3
object properties represent the state of an object and object method represents the behavior of that object.
example:
Suppose you have a Student object, its property could be name which represents the name of that student and its method could be to enroll in a course which represents the behavior of that student.