Feedback for ES decorator proposal
See original GitHub issueI’ve been contacted by @wycats (who is the champion of the ES decorator proposal at TC39) to provide feedback for the proposal from framework authors’ perspective, and since this library (and vue-property-decorators
) is the primary use case where Vue leverages decorators, I’m hosting the thread here.
I know there are a few discrepancies between ES and TS decorators, but am not 100% clear on the details. Ideally, I hope we can use vue-class-component
and vue-property-decorators
in both ES and TS contexts.
Would appreciate thoughts from @ktsn and @kaorun343 on this topic.
Issue Analytics
- State:
- Created 6 years ago
- Reactions:1
- Comments:13 (4 by maintainers)
Top Results From Across the Web
Decorators details
Decorators are a proposal for extending JavaScript classes which is widely adopted among developers in transpiler environments, with broad interest in ...
Read more >Exploring EcmaScript Decorators
Yehuda's decorators proposal seeks to enable annotating and modifying JavaScript classes, properties and object literals at design time while keeping a syntax ...
Read more >babel/plugin-proposal-decorators
npm install --save-dev @babel/plugin-proposal-decorators ... This option was added to help tc39 collect feedback from the community by allowing ...
Read more >Decorators make it to stage 3 : r/javascript - Reddit
97 votes, 42 comments. ... 42 comments sorted by Best ... This proposal would make them officially part of the ECMAscript spec.
Read more >JavaScript metaprogramming with the 2022-03 decorators API
[2022-10-18] dev, javascript, es proposal. (Ad, please don't block). JavaScript decorators ... 2014-04-10: Decorators were proposed to TC39 by Yehuda Katz.
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Afraid to sound stupid, but after almost two years I’m still not getting the real value of decorators.
I must agree with @carlsmith https://github.com/coffeescript6/discuss/issues/9#issuecomment-235975114 that decorators are just a fancier way to write wrappers.
And it even doesn’t look natural in JavaScript, since it would be the only operator (probably, alongside the
case 'value':
operator), which breaking a regular JS premise to define strict scopes with{}
.It just looks ripped off from Python and alienly slapped on syntax with quite different philisophy.
In worst scenario it should be something like
Yes, we intend to align once the proposal stabilizes.