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

Do not run the babel helper in Development Mode. (#782) #785

Merged
merged 1 commit into from
May 20, 2021

Conversation

tmeyer2115
Copy link
Collaborator

This PR adds a check to the babel helper to see if we are currently in the Development Mode. If
so, the enclosed source code is not run through Babel, it is returned verbatim. This is a preview
optimization, since the Babel-ification is a relatively slow operation. It's not necessary for
preview either, assuming devs are not previewing their changes in IE11.

There will need to be a corresponding Jambo PR for this as well. Jambo still has a babel helper
of its own for legacy reasons.

J=SLAP-1312
TEST=manual

Ensured that when in Development mode, the helper was a simple pass-through. In Production mode,
the enclosed code was Babel-ified.

This PR adds a check to the `babel` helper to see if we are currently in the Development Mode. If
so, the enclosed source code is not run through Babel, it is returned verbatim. This is a preview
optimization, since the Babel-ification is a relatively slow operation. It's not necessary for
preview either, assuming devs are not previewing their changes in IE11.

There will need to be a corresponding Jambo PR for this as well. Jambo still has a `babel` helper
of its own for legacy reasons.

J=SLAP-1312
TEST=manual

Ensured that when in Development mode, the helper was a simple pass-through. In Production mode,
the enclosed code was Babel-ified.
@coveralls
Copy link

Coverage Status

Coverage remained the same at 5.417% when pulling b0a89bd on feature/optimize-babel-helper into 78a6b96 on develop.

@tmeyer2115 tmeyer2115 merged commit a0f8092 into develop May 20, 2021
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

Successfully merging this pull request may close these issues.

None yet

2 participants