3 ms·
I'll admit I'm not very familiar with the original draft proposal and I appreciate the intentions and the desire to make it a bit more accessible to pragmatic p
by po 14y ago
I'll admit I'm not very familiar with the original draft proposal and I appreciate the intentions and the desire to make it a bit more accessible to pragmatic people but please indulge me on a little rant here:
I could not dislike the 'my-' prefix any more. Can we please as an industry of professionals decide to talk about things without having to baby talk it into a who's-on-first routine? Talking about variables in the first person possessive is difficult when the 'person' we are talking about owning it is an abstract block of code. In this proposal it is 'author defined' but really when I read your code, It is yours… and now it's mine… or maybe it's ours. Or perhaps it belongs to that block of code. What doesn't change is that it's a variable (or property).
I know that's probably a minor point but it annoys me.
Secondly, I think the $() syntax needs to be weighed against the cost of having nesting there. Is $ not enough to indicate a reference? I guess the idea is to use that to provide a default but I don't like having to always type out the parens for it.
- bkardell 14y agoA link to the draft in github is in the article so fork, send a pull, suggest away. I would suggest a read through the variables draft and a search on hn and www-style list to see the previous confusion caused by using not just the word variable, but the prefix var- and non-paren form you suggest.
- po 14y agoI hope it doesn't come off as too harsh. I mean it in a good-natured way and obviously you're putting forward your ideas which is a good thing. Why do you think the term 'variable' is the source of confusion and 'property' is better? If so, why not use a 'prop-' prefix?
- bkardell 14y agoNo, not at all. We considered lots of things that could work: prop, map, author, def, store... The more discussion and argument the better IMO.