Dynamic Properties is an actively used design pattern. Some OO languages like Python and Javascript allow you to set and access properties on instances at runtime that are not defined in the class definition.

?Years Old
  • Have a question about Dynamic Properties not answered here? Email me and let me know how I can help.

Languages with Dynamic Properties include javascript, python

Example from javascript:

class Person {}
const person = new Person()
person.age = 50

Example from python:

class Person (object):
  def __init__(self, name):
   self.name = name

person = Person("John")
person.age = 50

Last updated June 22nd, 2020

Edit Dynamic Properties on GitHub