Skip to content
This repository has been archived by the owner on May 11, 2018. It is now read-only.

How to handle stage-x #14

Closed
hzoo opened this issue Oct 7, 2016 · 4 comments
Closed

How to handle stage-x #14

hzoo opened this issue Oct 7, 2016 · 4 comments

Comments

@hzoo
Copy link
Member

hzoo commented Oct 7, 2016

Do we want to allow for users to stage-x plugins with this preset as well?
Or should this only cover for everything under latest?

Since browsers don't implement stage-x features anyway (otherwise they'd be stage-4), it would be only supported by browsers through a flag...

Maybe we should just leave it alone and users will just specify stage-x presets individually?

{
  "presets": [
    ["env", {
      "targets": {
        "chrome": 52
      }
    }],
    "stage-2"
  ]
}

Actually now that I think about that seems fine?

@milesj
Copy link

milesj commented Oct 7, 2016

My vote is for not supporting stage-x features.

  1. They're possibly not implemented natively.
  2. If they are, they can be behind flags (like you said), which simply opens up to many configuration possibilities to support.
  3. We should focus on solidifying the accuracy of features that are supported natively.

@AvivRubys
Copy link

If there's a case, or could be in the future a case, where a vendor has implemented stage-x features without any special flags needed, then the project should definitely take advantage of that.
However, I'm not that familiar with the stage system - is that a likely or even possible scenario?

@hzoo
Copy link
Member Author

hzoo commented Oct 7, 2016

Agreed, Yeah after I brought it up it doesn't really make sense to do except under a flag/canary release for a browser and that would only be at minimum stage 3 by definition anyway.

We would only do this if you were using that for development and wanted the clearer output etc instead if source maps or something - not really a priority unless someone wants to take this on.

@hzoo
Copy link
Member Author

hzoo commented Oct 8, 2016

Ok yeah it makes sense to just support all plugins in latest (http://babeljs.io/docs/plugins/preset-latest/) - currently up to es2017.

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

3 participants