Skip to content

There must be a way to provide Babel options #521

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

Closed
s-panferov opened this issue Aug 8, 2015 · 5 comments
Closed

There must be a way to provide Babel options #521

s-panferov opened this issue Aug 8, 2015 · 5 comments

Comments

@s-panferov
Copy link

Hello! Thanks for the awesome project.

I found the feature #475 with optional babel support very useful. But it seems incomplete to me, because there must be a way to specify Babel's options. Existed solutions like https://babeljs.io/docs/usage/babelrc/ don't work (or I'm doing something wrong).

@s-panferov
Copy link
Author

Maybe we can offer the second extended form of the externalTranspiler option?

"externalTranspiler": {
    name: "babel",
    options: {
        /* babel options goes here */
    }
}

Or maybe there is a way to make .babelrc work?

@basarat
Copy link
Member

basarat commented Aug 10, 2015

Maybe we can offer the second extended form of the externalTranspiler option

I like the simplicity of this 🌹

Closed by #523

@tomitrescak
Copy link

How does this work? I set this, I have babel installed in my node_modeuls dir, yet no transpilation with babel hapens. Also, the options are not available, I need to use babel plugins.

@basarat
Copy link
Member

basarat commented Apr 22, 2016

@tomitrescak personally I've never used this option so can't be much help. With the TypeScript compiler getting a transformer based emitter soon, we wouldn't need to offload heavy plug-gable emitting to babel hopefully 🌹

Still docs https://github.com/TypeStrong/atom-typescript/blob/master/docs/faq.md#can-i-use-an-alternate-transpiler

@nycdotnet
Copy link
Contributor

It calls Babel on the emitted result before writing it to disk. This was a bit of a hack to get let for loops working pre-1.8 and it includes babel 5. Look at the referenced PR.

@TypeStrong TypeStrong locked and limited conversation to collaborators Jan 20, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants