Skip to content

Commit

Permalink
Canary Hermes for-of
Browse files Browse the repository at this point in the history
Summary:
This diff canary Hermes for-of by conditionalizing the
`babel/plugin-transform-for-of` transform

Reviewed By: motiz88

Differential Revision: D27351717

fbshipit-source-id: 5758b6b578a864e189c533d8e1a874709c884514
  • Loading branch information
Huxpro authored and facebook-github-bot committed Mar 26, 2021
1 parent 17d4761 commit f66d6e3
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ const getPreset = (src, options) => {
if (!isHermes && (isNull || src.indexOf('Object.assign')) !== -1) {
extraPlugins.push([require('@babel/plugin-transform-object-assign')]);
}
if (hasForOf) {
if (!isHermesCanary && hasForOf) {
extraPlugins.push([
require('@babel/plugin-transform-for-of'),
{loose: true},
Expand Down

0 comments on commit f66d6e3

Please sign in to comment.