Skip to content
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

Update babylon plugins in BabylonParser, solves #3070 #3076

Merged
merged 2 commits into from
Mar 6, 2017

Conversation

etiennedi
Copy link

Summary

Solves #3070. Instead of including only the 'flow' babylon plugin, all available babylon plugins are included. As a result, parsing files containing JSX does not produce an error.

Test plan
Added a test case to fixtures/global_its.example and fixtures/global_its.example. The test checks whether parsing works with JSX:

it('works with JSX', ()=> {
  const foo = () => <div></div>;
})

This test wouldn't pass without the change. It does pass with the change.

@cpojer cpojer merged commit cec138b into jestjs:master Mar 6, 2017
@cpojer
Copy link
Member

cpojer commented Mar 6, 2017

Nice work! Thanks.

@yacut
Copy link

yacut commented Apr 3, 2017

The changes were not published. The 19.0.2 version still has old code: babel.plugins.concat(['flow']):['flow'];
@cpojer, could you please check it?

skovhus pushed a commit to skovhus/jest that referenced this pull request Apr 29, 2017
)

* change babylon plugins to all, fixes jestjs#3070

* increase minimum required babylon version for new features to work
tushardhole pushed a commit to tushardhole/jest that referenced this pull request Aug 21, 2017
)

* change babylon plugins to all, fixes jestjs#3070

* increase minimum required babylon version for new features to work
@github-actions
Copy link

This pull request has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
Please note this issue tracker is not a help forum. We recommend using StackOverflow or our discord channel for questions.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators May 13, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants