Attribute vs Parameter vs Property


Attributes and properties are terms frequently used interchangeably! The definitions of these two terms are very much relevant to the context within which they are used, and different programming languages will have different interpretations. Below is my general interpretation of attributes vs parameters vs properties.

  • Elements and variables have attributes, e.g. type or src.
  • Objects have properties, e.g. class variables and methods.
  • Functions / methods have parameters, which are the input variables or values guiding operations.
  • Calls to APIs and functions / methods have arguments.

Discover more from Titan Fusion

Subscribe to get the latest posts sent to your email.

,

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Discover more from Titan Fusion

Subscribe now to keep reading and get access to the full archive.

Continue reading