Create a simple class to expose dictionary keys with dot notation

August 11, 2022

class DotNotation:
    def __init__(self, settings: dict) -> None:
        self.__dict__ = settings
 
a = DotNotation({"key": "value"})
assert a.key == "value"