Python equivalent of Typescript interface
For the code completion and type hinting in IDEs, just add static typing for the Person and Address classes and you are already good to go. Assuming you use the latest python3.6, here’s a rough equivalent of the typescript classes from your example: # spam.py from typing import Optional, Sequence class Address: street: str housenumber: … Read more