-
Notifications
You must be signed in to change notification settings - Fork 68
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Consider replacing AttrDict with built-in dict #66
Comments
Thanks for opening your first issue here! Engagement like this is essential for open source projects! 🤗 |
@chrisjsewell What do you think about this one? If you like the idea, then it would be a good idea to implement this before v1.0.0 I think. |
I’ll defer to you two to decide, though I think the points you bring up here do make sense. It is always awkward using attribute for value retrieval when you can use keys that are not valid attribute names. |
I can see the thinking for using an AttrDict for
options
andenv
: it provides a syntax that looks like JS object attribute access in "mother" markdown-it, and might make porting of JS extensions etc more straightforward.I feel, however, that for the purpose the AttrDict is used for, i.e. a container of dynamically named data, a simple builtin dict might be the "Python native" equivalent.
The disadvantages of AttrDict that I can see:
The advantages might be:
The text was updated successfully, but these errors were encountered: