Skip to content

babel 7 support #42

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
jakewhelan opened this issue Apr 12, 2018 · 8 comments
Closed

babel 7 support #42

jakewhelan opened this issue Apr 12, 2018 · 8 comments

Comments

@jakewhelan
Copy link

I'm currently modernising an angular 1.5 app

I would like to use babel 7 but this plugin has not been updated, are there any plans for this update?

@p3x-robot
Copy link

same here, stopped working with @babel 7

@p3x-robot
Copy link

did you disabled mangling? like before it worked, i upgraded something and now i have to disable mangling...

@p3x-robot
Copy link

looks like babel has changed something i think

@p3x-robot
Copy link

#40 (comment)

@schmod
Copy link
Owner

schmod commented May 8, 2018

@p3x-robot This repo is maintained. Please feel free to open a PR if you'd like to fix this.

@StabbarN
Copy link

I use this plugin together with babel 7 without any problems.

@pioug pioug mentioned this issue May 12, 2018
@pioug
Copy link

pioug commented May 14, 2018

I created a PR #43. I am not very sure of my changes since I don't follow closely the evolution of Babel but tests are passing 🙏

@jakewhelan
Copy link
Author

jakewhelan commented Aug 12, 2018

Thanks for arousing my interest @StabbarN, I've since discovered this indeed works with Babel 7 - you just need to require it rather than using the string literal reference as instructed in the README.

module.exports = {
  presets: [
    '@babel/preset-env'
  ],
  plugins: [
    require('babel-plugin-angularjs-annotate'),
    'proposal-optional-chaining'
  ]
}

Though now that I think about it, this should also work just fine:

module.exports = {
  presets: [
    '@babel/preset-env'
  ],
  plugins: [
    'angularjs-annotate',
    'proposal-optional-chaining'
  ]
}

I think all the package naming changes just threw me off.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants