{"action":"created","issue":{"url":"https://api.github.com/repos/tc39/proposal-class-fields/issues/100","repository_url":"https://api.github.com/repos/tc39/proposal-class-fields","labels_url":"https://api.github.com/repos/tc39/proposal-class-fields/issues/100/labels{/name}","comments_url":"https://api.github.com/repos/tc39/proposal-class-fields/issues/100/comments","events_url":"https://api.github.com/repos/tc39/proposal-class-fields/issues/100/events","html_url":"https://github.com/tc39/proposal-class-fields/issues/100","id":320925205,"node_id":"MDU6SXNzdWUzMjA5MjUyMDU=","number":100,"title":"A summary of feedback regarding the # sigil prefix","user":{"login":"glen-84","id":261509,"node_id":"MDQ6VXNlcjI2MTUwOQ==","avatar_url":"https://avatars0.githubusercontent.com/u/261509?v=4","gravatar_id":"","url":"https://api.github.com/users/glen-84","html_url":"https://github.com/glen-84","followers_url":"https://api.github.com/users/glen-84/followers","following_url":"https://api.github.com/users/glen-84/following{/other_user}","gists_url":"https://api.github.com/users/glen-84/gists{/gist_id}","starred_url":"https://api.github.com/users/glen-84/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/glen-84/subscriptions","organizations_url":"https://api.github.com/users/glen-84/orgs","repos_url":"https://api.github.com/users/glen-84/repos","events_url":"https://api.github.com/users/glen-84/events{/privacy}","received_events_url":"https://api.github.com/users/glen-84/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":382,"created_at":"2018-05-07T19:25:26Z","updated_at":"2018-11-22T02:42:31Z","closed_at":"2018-10-10T14:16:03Z","author_association":"NONE","body":"<table>\r\n    <thead>\r\n        <tr>\r\n            <th>Issue/comment</th>\r\n            <th>👍</th>\r\n            <th>👎</th>\r\n            <th>🎉</th>\r\n            <th>❤️</th>\r\n        </tr>\r\n    </thead>\r\n    <tbody>\r\n        <tr>\r\n            <td><a href=\"https://github.com/tc39/proposal-private-methods/issues/10\">Stop this proposal</a></td>\r\n            <td>196</td>\r\n            <td>31</td>\r\n            <td>20</td>\r\n            <td>45</td>\r\n        </tr>\r\n        <tr>\r\n            <td><a href=\"https://github.com/tc39/proposal-private-fields/issues/14\">Why not use the \"private\" keyword, like Java or C#?</a></td>\r\n            <td>132</td>\r\n            <td>7</td>\r\n            <td>12</td>\r\n            <td>5</td>\r\n        </tr>\r\n        <tr>\r\n            <td><a href=\"https://github.com/tc39/proposal-private-fields/issues/14#issuecomment-216042553\">Why not use the \"private\" keyword, like Java or C#?</a> 💬</td>\r\n            <td>144</td>\r\n            <td>0</td>\r\n            <td>16</td>\r\n            <td>9</td>\r\n        </tr>\r\n        <tr>\r\n            <td><a href=\"https://github.com/tc39/proposal-private-fields/issues/14#issuecomment-216304000\">Why not use the \"private\" keyword, like Java or C#?</a> 💬</td>\r\n            <td>51</td>\r\n            <td>0</td>\r\n            <td>0</td>\r\n            <td>0</td>\r\n        </tr>\r\n        <tr>\r\n            <td><a href=\"https://github.com/tc39/proposal-class-fields/issues/6\">Private Properties Syntax</a></td>\r\n            <td>33</td>\r\n            <td>4</td>\r\n            <td>0</td>\r\n            <td>0</td>\r\n        </tr>\r\n        <tr>\r\n            <td><a href=\"https://github.com/tc39/proposal-private-methods/issues/28\">Yet another approach to a more JS-like syntax</a></td>\r\n            <td>32</td>\r\n            <td>0</td>\r\n            <td>0</td>\r\n            <td>41</td>\r\n        </tr>\r\n        <tr>\r\n            <td><a href=\"https://github.com/tc39/proposal-private-methods/issues/20\">New, more JS-like syntax</a></td>\r\n            <td>32</td>\r\n            <td>4</td>\r\n            <td>0</td>\r\n            <td>0</td>\r\n        </tr>\r\n        <tr>\r\n            <td><a href=\"https://github.com/tc39/proposal-class-fields/issues/77\">Please do not use \"#\"</a></td>\r\n            <td>32</td>\r\n            <td>0</td>\r\n            <td>1</td>\r\n            <td>1</td>\r\n        </tr>\r\n        <tr>\r\n            <td><a href=\"https://github.com/tc39/proposal-class-fields/issues/56\">Proposal: keyword to replace `#` sigil</a></td>\r\n            <td>18</td>\r\n            <td>0</td>\r\n            <td>0</td>\r\n            <td>1</td>\r\n        </tr>\r\n        <tr>\r\n            <td><a href=\"https://github.com/tc39/proposal-private-methods/issues/8\">Why not use private keyword instead of #?</a></td>\r\n            <td>16</td>\r\n            <td>0</td>\r\n            <td>0</td>\r\n            <td>1</td>\r\n        </tr>\r\n        <tr>\r\n            <td><a href=\"https://github.com/zenparsing/js-classes-1.1/issues/40\">Explore a more JS-like syntax</a></td>\r\n            <td>7</td>\r\n            <td>0</td>\r\n            <td>0</td>\r\n            <td>0</td>\r\n        </tr>\r\n        <tr>\r\n            <td><a href=\"https://github.com/tc39/proposal-class-fields/issues/99\">The '#' looks awful, please change it</a></td>\r\n            <td>9</td>\r\n            <td>4</td>\r\n            <td>0</td>\r\n            <td>0</td>\r\n        </tr>\r\n        <tr>\r\n            <td><a href=\"https://github.com/tc39/proposal-private-fields/issues/92\">can we just use private keyword?</a></td>\r\n            <td>2</td>\r\n            <td>0</td>\r\n            <td>0</td>\r\n            <td>0</td>\r\n        </tr>\r\n        <tr>\r\n            <td><a href=\"https://github.com/tc39/proposal-class-fields/issues/142\">Do we still have a chance to stop private fields (with #)?</a></td>\r\n            <td>3</td>\r\n            <td>3</td>\r\n            <td>1</td>\r\n            <td>1</td>\r\n        </tr>\r\n        <tr>\r\n            <td><a href=\"https://github.com/tc39/proposal-class-fields/issues/149\">[Private] yet another alternative to `#`-based syntax</a></td>\r\n            <td>3</td>\r\n            <td>0</td>\r\n            <td>0</td>\r\n            <td>0</td>\r\n        </tr>\r\n        <tr>\r\n            <td><a href=\"https://github.com/tc39/proposal-class-fields/issues/153\">and yet another suggestion for \"private but not closure\"</a></td>\r\n            <td>0</td>\r\n            <td>0</td>\r\n            <td>0</td>\r\n            <td>0</td>\r\n        </tr>\r\n        <tr>\r\n            <td><a href=\"https://github.com/tc39/proposal-class-fields/issues/138\">Why don't use `private` instead of `#`?</a></td>\r\n            <td>0</td>\r\n            <td>3</td>\r\n            <td>0</td>\r\n            <td>0</td>\r\n        </tr>\r\n        <tr>\r\n            <td><a href=\"https://github.com/tc39/proposal-class-fields/issues/116\">Why \"private\" and \"protected\" future reserved keywords are not used?</a></td>\r\n            <td>0</td>\r\n            <td>0</td>\r\n            <td>0</td>\r\n            <td>0</td>\r\n        </tr>\r\n    </tbody>\r\n</table>\r\n\r\nOther feedback:\r\n\r\n* http://2ality.com/2017/07/class-fields.html\r\n    * From the comments: \"I'd rather shoot myself in the face than use hashtags for private fields.\"\r\n        * 33 upvotes (comments closed)\r\n* [ES Next Features That'll Make You Dance](https://www.youtube.com/watch?v=9yK4t2CuIHQ)\r\n    * [\"And beware, you may have an adverse reaction ...\"](https://youtu.be/9yK4t2CuIHQ?t=1148)\r\n    * [\"Oh, I heard somebody groan!\"](https://youtu.be/9yK4t2CuIHQ?t=1160)\r\n    * Some comments:\r\n        * > #method() is gross, at least I use typescript and don't have to look at it. 👍30\r\n        * > So ES is becoming the new PHP \"ugly-wise\"? So glad i use typescript. They should have delayed that private method feature some more and thought some more to really avoid having that absolutely terrible, horrible looking # syntax. Ew.. In code everything is possible. EVERYTHING (if your not into computer science). If they have to break backward compat then so be it. So very bad.\r\n        * > I am excited about getting new features and I like to see things continuing to grow, I am not liking that private property syntax in the function, it looks like a comment and makes me shudder... everyone should be aware of this \"fact\" - every time someone gets confused and thinks the # symbol is actually a comment when JavaScript should have used the word private to declare a private entity, a bag of kittens gets thrown into a wood chipper, very sad.﻿\r\n        * > Fix the private keyword issue please! The proposed syntax is not only inconsistent with the static declaration but also looks like a comment!\r\n\r\nThe TypeScript team are [not fond of](https://github.com/Microsoft/TypeScript/issues/16415) the syntax either.\r\n\r\nMy suggestion to rename the proposal: https://github.com/tc39/proposal-private-fields/issues/72\r\n(the idea is mainly about making it a lower-level feature, and making room for a cleaner syntax at a later date)\r\n\r\n@littledan @bakkot @ljharb – I apologize in advance, as I know that you must be thinking \"Oh g*d, not again!\", but I just wanted to put this all in one place, and allow the community to share their opinion in the form of reactions. It would be great if you could keep this open for a while (30 days?), or perhaps even indefinitely to prevent other users from submitting even more issues on the same topic.\r\n\r\nTo the non-committee members reading this: These proposals are now at stage 3, so it's unlikely that a syntax change will occur, but please feel free to up-vote this issue if you feel that the sigil (`#`) prefix is not a good fit for the language, or down-vote the issue if you believe that it's perfectly acceptable."},"comment":{"url":"https://api.github.com/repos/tc39/proposal-class-fields/issues/comments/440895823","html_url":"https://github.com/tc39/proposal-class-fields/issues/100#issuecomment-440895823","issue_url":"https://api.github.com/repos/tc39/proposal-class-fields/issues/100","id":440895823,"node_id":"MDEyOklzc3VlQ29tbWVudDQ0MDg5NTgyMw==","user":{"login":"rdking","id":2289634,"node_id":"MDQ6VXNlcjIyODk2MzQ=","avatar_url":"https://avatars0.githubusercontent.com/u/2289634?v=4","gravatar_id":"","url":"https://api.github.com/users/rdking","html_url":"https://github.com/rdking","followers_url":"https://api.github.com/users/rdking/followers","following_url":"https://api.github.com/users/rdking/following{/other_user}","gists_url":"https://api.github.com/users/rdking/gists{/gist_id}","starred_url":"https://api.github.com/users/rdking/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rdking/subscriptions","organizations_url":"https://api.github.com/users/rdking/orgs","repos_url":"https://api.github.com/users/rdking/repos","events_url":"https://api.github.com/users/rdking/events{/privacy}","received_events_url":"https://api.github.com/users/rdking/received_events","type":"User","site_admin":false},"created_at":"2018-11-22T02:42:31Z","updated_at":"2018-11-22T02:42:31Z","author_association":"NONE","body":"@mbrowne Saying I'm nitpicking is a meaningless jab. The devil is in the details. If you're not willing to scrutinize the details, you'll miss opportunities. The `=` makes it clear that what's being defined is a data property as opposed to a function property. That distinction is important all by itself and `=` is well suited to that purpose. However, what in the declaration makes it clear that this property isn't going where all other declarations are going?\r\n\r\n> Yes, the presence of a keyword makes the difference a bit more obvious but your argument is weak, especially considering that people with experience in other OOP languages (and of course Babel/TypeScript) probably already expect x = ... notation to add a property to the instance (not to the prototype or the constructor function).\r\n\r\nStrawman argument again. Other OOP languages are class-based, not prototype based. They have metadata for the class template. All class properties are automatically on the instance **because there's no other place for them to be!** In prototype-based languages, **the prototype is the template**.\r\n\r\nMy argument isn't as weak as you try to make it out to be. Look at how `class` currently works:\r\n* `static` makes it clear this declaration is going on the constructor instead of the prototype.\r\n* `get/set` makes it clear this declaration is going into a property definition to be applied to a prototype.\r\n* all declarations without a keyword prefix go on the prototype\r\n\r\nNotice that declarations use keywords when the declaration doesn't get applied directly to the prototype? That's the precedent for my argument. There's no way that matching pattern in the existing language constitutes a \"weak argument\".\r\n\r\n> There's nothing that makes it immediately clear that it's per-instance. In fact when I first saw it, I thought it looked like a private class-scoped (static) variable.\r\n\r\nI might have to relent on that one, but I'm not so sure. Currently no definition in the class declaration exists without being instantiated unless it uses the `static` keyword. My proposal continues that pattern. It's not static if it doesn't use `static`. In my mind, this makes it fairly easy to reason about what is an instance member and what is not. How will others see it? I can't say, but I would hope a brief explanation would be more than sufficient to bring anyone up to speed.\r\n"}}
{"actor":{"display_login":"rdking"}}