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
How to test static decorator proposal #296
Comments
Thanks for the references. I was seeing folks talk about using this proposal so I assumed there was some way to do so. I'm not wedded to Babel as the only way... any way would be welcome at this point. |
Substitute babel with any transpiler - it’s not yet clear how it will be possible to use the new proposal prior to a native implementation. |
It will definitely be possible. That a transpiler might have to load more than one file doesn't make it impossible. This would be true of any macro-like system where you want to do expansion at build time - the compiler needs the macro definitions. |
I will open a PR to the Babel repo in less than a month, with support for decorators defined in the same file. It's not full support for what this proposal specifies yet, but it will allow you to experiment with it. |
@justinfagnani there also has to be a way to support both native and nonnative decorators in the dep graph at the same time, or else ecosystem usage will be forked between native and transpiled. It’d be better for babel not to add any support, than for that to happen. |
@ljharb You've raised these issues in several threads before; it's a bit off-topic to repeat yourself here. I think these questions all have good answers, some of which will be provided constructively by an implementation, and others of which will have documentation improvements. If you want to test out static decorators, you can help move that along by reviewing @nicolo-ribaudo 's in-progress implementation at babel/babel#10388 |
This can probably be closed now that the proposal has been rewritten? |
I worked extensively with the previous, dynamic Stage 2 proposal using Babel. It does not appear to support the new static proposal, so is there any way to experiment with this and provide feedback?
The text was updated successfully, but these errors were encountered: