Merge pull request #3235 from guybedford/polyfillRuntime

Ensure opts.polyfill = false behaves correctly for runtime-transformer
This commit is contained in:
Sebastian McKenzie
2016-01-06 15:23:41 +00:00

View File

@@ -33,6 +33,8 @@ export default function ({ types: t }) {
return;
}
if (state.opts.polyfill === false) return;
if (t.isMemberExpression(parent)) return;
if (!has(definitions.builtins, node.name)) return;
if (scope.getBindingIdentifier(node.name)) return;