-
Notifications
You must be signed in to change notification settings - Fork 62
kwArgs #28
Comments
No strong opinion here. kwargs comes from Python, and Alex and I had both spent some significant time working with Python just before starting Dojo. |
My two cents: |
I could see switching from This will need to be find/replaced in any repos it's used (primarily core). As @kitsonk pointed out in a comment elsewhere, we should probably figure out a good place to mention this in the style guide. |
I suppose my one reservation about the name |
|
In some places they are options, but in other places they are things that are mixed into an object. I could see using |
If we're going from one name to conditionally using one of two names, I think we're creating a problem, not solving one... |
I'm not sure how being more descriptive with an API is creating a problem. Is it more work for the API writer? Sure. But is it more to learn for an API consumer? Not really. It still behaves the same as |
Coming from Dojo 1's perspective at least, I can't easily think of any places offhand where an object is passed to the constructor and isn't mixed into the instance. And if this question is about deciding what to call a thing, from the perspective of not liking what we call it now, calling it 2 different things seems to be adding more complexity and tending towards "just throw up your hands and call it whatever you feel like in each particular case". I agree Would just lopping off |
I'm a big fan of the "just throw up your hands and call it whatever you feel like in each particular case." I don't think |
I think for downstream code, "just throw up your hands" is ok, but in a toolkit, we have to be specific and provide a guideline and be pedantic about the little things. I find I noticed Intern uses |
Closing this in lieu of dojo/meta#7. |
Are we really wedded to
kwArgs
instead of something likeoptions
?I know it is a small thing, but honestly I never like the name
kwArgs
, it just seems like some sort of clique sort of argument name, versus something that is a bit more clear of intent. Thoughts?The text was updated successfully, but these errors were encountered: