@fullstory/babel-plugin-react-native
Advanced tools
Comparing version 1.2.0 to 1.2.1
@@ -14,3 +14,3 @@ "use strict"; | ||
var _createFabricRefCode = function _createFabricRefCode(refIdentifier, typeIdentifier, propsIdentifier) { | ||
return "\n const SUPPORTED_FS_ATTRIBUTES = [\n 'fsClass',\n 'fsAttribute',\n 'fsTagName',\n 'dataElement',\n 'dataComponent',\n 'dataSourceFile',\n ]; \n if (global.__turboModuleProxy != null && Platform.OS === 'ios') {\n if (".concat(typeIdentifier, ".$$typeof && (").concat(typeIdentifier, ".$$typeof.toString() === 'Symbol(react.forward_ref)' || ").concat(typeIdentifier, ".$$typeof.toString() === 'Symbol(react.element)')) {\n if (").concat(propsIdentifier, ") {\n const propContainsFSAttribute = SUPPORTED_FS_ATTRIBUTES.some(fsAttribute => {\n return typeof ").concat(propsIdentifier, "[fsAttribute] === 'string' && !!").concat(propsIdentifier, "[fsAttribute];\n });\n \n if (propContainsFSAttribute) {\n const fs = require('@fullstory/react-native');\n ").concat(refIdentifier, " = fs.applyFSPropertiesWithRef(").concat(refIdentifier, ");\n }\n }\n }\n }"); | ||
return "\n const { Platform } = require('react-native');\n const SUPPORTED_FS_ATTRIBUTES = [\n 'fsClass',\n 'fsAttribute',\n 'fsTagName',\n 'dataElement',\n 'dataComponent',\n 'dataSourceFile',\n ]; \n if (global.__turboModuleProxy != null && Platform.OS === 'ios') {\n if (".concat(typeIdentifier, ".$$typeof && (").concat(typeIdentifier, ".$$typeof.toString() === 'Symbol(react.forward_ref)' || ").concat(typeIdentifier, ".$$typeof.toString() === 'Symbol(react.element)')) {\n if (").concat(propsIdentifier, ") {\n const propContainsFSAttribute = SUPPORTED_FS_ATTRIBUTES.some(fsAttribute => {\n return typeof ").concat(propsIdentifier, "[fsAttribute] === 'string' && !!").concat(propsIdentifier, "[fsAttribute];\n });\n \n if (propContainsFSAttribute) {\n const fs = require('@fullstory/react-native');\n ").concat(refIdentifier, " = fs.applyFSPropertiesWithRef(").concat(refIdentifier, ");\n }\n }\n }\n }"); | ||
}; | ||
@@ -17,0 +17,0 @@ |
{ | ||
"name": "@fullstory/babel-plugin-react-native", | ||
"version": "1.2.0", | ||
"version": "1.2.1", | ||
"description": "The official FullStory React Native babel plugin", | ||
@@ -5,0 +5,0 @@ "repository": "git://github.com/fullstorydev/fullstory-babel-plugin-react-native.git", |
24916