-
Is there an appropriate way to say that the datatype of the def add_card_to_page(q: Q, card, card_name: str) -> None:
"""
Display a card which we would want to remove on page change
"""
q.page[card_name] = card
q.client.active_cards.append(card_name) |
Beta Was this translation helpful? Give feedback.
Answered by
lo5
Jul 17, 2021
Replies: 1 comment
-
The cards don't inherit from a common base class. Anything that is either a |
Beta Was this translation helpful? Give feedback.
0 replies
Answer selected by
mtanco
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The cards don't inherit from a common base class. Anything that is either a
dict
or an object with adump() -> dict
method can be added to a page. The API usesAny
since I'm not aware of a precise way to express this usingtyping
.