posthog-react-native 2.11.5 → 2.11.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- "use strict";var _interopRequireDefault=require("@babel/runtime/helpers/interopRequireDefault");var _typeof=require("@babel/runtime/helpers/typeof");Object.defineProperty(exports,"__esModule",{value:true});exports.PostHogProvider=void 0;var _slicedToArray2=_interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));var _react=_interopRequireWildcard(require("react"));var _reactNative=require("react-native");var _posthogRn=require("./posthog-rn");var _autocapture=require("./autocapture");var _useNavigationTracker=require("./hooks/useNavigationTracker");var _useLifecycleTracker=require("./hooks/useLifecycleTracker");var _PosthogContext=require("./PosthogContext");var _this=void 0,_jsxFileName="/home/runner/work/posthog-js-lite/posthog-js-lite/posthog-react-native/lib/posthog-react-native/src/PostHogProvider.js";function _getRequireWildcardCache(nodeInterop){if(typeof WeakMap!=="function")return null;var cacheBabelInterop=new WeakMap();var cacheNodeInterop=new WeakMap();return(_getRequireWildcardCache=function _getRequireWildcardCache(nodeInterop){return nodeInterop?cacheNodeInterop:cacheBabelInterop;})(nodeInterop);}function _interopRequireWildcard(obj,nodeInterop){if(!nodeInterop&&obj&&obj.__esModule){return obj;}if(obj===null||_typeof(obj)!=="object"&&typeof obj!=="function"){return{"default":obj};}var cache=_getRequireWildcardCache(nodeInterop);if(cache&&cache.has(obj)){return cache.get(obj);}var newObj={};var hasPropertyDescriptor=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var key in obj){if(key!=="default"&&Object.prototype.hasOwnProperty.call(obj,key)){var desc=hasPropertyDescriptor?Object.getOwnPropertyDescriptor(obj,key):null;if(desc&&(desc.get||desc.set)){Object.defineProperty(newObj,key,desc);}else{newObj[key]=obj[key];}}}newObj["default"]=obj;if(cache){cache.set(obj,newObj);}return newObj;}function PostHogNavigationHook(_ref){var options=_ref.options,client=_ref.client;(0,_useNavigationTracker.useNavigationTracker)(options===null||options===void 0?void 0:options.navigation,client);return null;}function PostHogLifecycleHook(_ref2){var client=_ref2.client;(0,_useLifecycleTracker.useLifecycleTracker)(client);return null;}var PostHogProvider=function PostHogProvider(_ref3){var children=_ref3.children,client=_ref3.client,options=_ref3.options,apiKey=_ref3.apiKey,autocapture=_ref3.autocapture,style=_ref3.style,_ref3$debug=_ref3.debug,debug=_ref3$debug===void 0?false:_ref3$debug;var _a,_b;var _useState=(0,_react.useState)(client instanceof Promise?undefined:client),_useState2=(0,_slicedToArray2["default"])(_useState,2),posthog=_useState2[0],setPosthog=_useState2[1];var autocaptureOptions=(0,_react.useMemo)(function(){return autocapture&&typeof autocapture!=='boolean'?autocapture:{};},[autocapture]);var captureAll=autocapture===true;var captureNone=autocapture===false;var captureTouches=!captureNone&&posthog&&(captureAll||(autocaptureOptions===null||autocaptureOptions===void 0?void 0:autocaptureOptions.captureTouches));var captureScreens=!captureNone&&posthog&&(captureAll||((_a=autocaptureOptions===null||autocaptureOptions===void 0?void 0:autocaptureOptions.captureScreens)!==null&&_a!==void 0?_a:true));var captureLifecycle=!captureNone&&posthog&&(captureAll||((_b=autocaptureOptions===null||autocaptureOptions===void 0?void 0:autocaptureOptions.captureLifecycleEvents)!==null&&_b!==void 0?_b:true));(0,_react.useEffect)(function(){if(client&&apiKey){console.warn('You have provided both a client and an apiKey to PostHogProvider. The apiKey will be ignored in favour of the client.');}if(!posthog&&client){if(client instanceof Promise){client.then(setPosthog);}else{setPosthog(client);}}else if(!posthog&&apiKey){_posthogRn.PostHog.initAsync(apiKey,options).then(setPosthog);}},[client,apiKey,posthog,options]);(0,_react.useEffect)(function(){if(!posthog){return;}posthog.debug(debug);},[debug,posthog]);var onTouch=(0,_react.useCallback)(function(type,e){if(!captureTouches){return;}if(type==='end'){(0,_autocapture.autocaptureFromTouchEvent)(e,posthog,autocaptureOptions);}},[captureTouches,posthog,autocaptureOptions]);return _react["default"].createElement(_reactNative.View,{"ph-label":"PostHogProvider",style:style||{flex:1},onTouchEndCapture:captureTouches?function(e){return onTouch('end',e);}:undefined,__self:_this,__source:{fileName:_jsxFileName,lineNumber:58,columnNumber:13}},_react["default"].createElement(_PosthogContext.PostHogContext.Provider,{value:{client:posthog},__self:_this,__source:{fileName:_jsxFileName,lineNumber:59,columnNumber:7}},_react["default"].createElement(_react["default"].Fragment,null,captureScreens?_react["default"].createElement(PostHogNavigationHook,{options:autocaptureOptions,client:posthog,__self:_this,__source:{fileName:_jsxFileName,lineNumber:61,columnNumber:29}}):null,captureLifecycle?_react["default"].createElement(PostHogLifecycleHook,{client:posthog,__self:_this,__source:{fileName:_jsxFileName,lineNumber:62,columnNumber:31}}):null),children));};exports.PostHogProvider=PostHogProvider;
1
+ "use strict";var _interopRequireDefault=require("@babel/runtime/helpers/interopRequireDefault");var _typeof=require("@babel/runtime/helpers/typeof");Object.defineProperty(exports,"__esModule",{value:true});exports.PostHogProvider=void 0;var _slicedToArray2=_interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));var _react=_interopRequireWildcard(require("react"));var _reactNative=require("react-native");var _posthogRn=require("./posthog-rn");var _autocapture=require("./autocapture");var _useNavigationTracker=require("./hooks/useNavigationTracker");var _useLifecycleTracker=require("./hooks/useLifecycleTracker");var _PosthogContext=require("./PosthogContext");var _this=void 0,_jsxFileName="/home/runner/work/posthog-js-lite/posthog-js-lite/posthog-react-native/lib/posthog-react-native/src/PostHogProvider.js";function _getRequireWildcardCache(nodeInterop){if(typeof WeakMap!=="function")return null;var cacheBabelInterop=new WeakMap();var cacheNodeInterop=new WeakMap();return(_getRequireWildcardCache=function _getRequireWildcardCache(nodeInterop){return nodeInterop?cacheNodeInterop:cacheBabelInterop;})(nodeInterop);}function _interopRequireWildcard(obj,nodeInterop){if(!nodeInterop&&obj&&obj.__esModule){return obj;}if(obj===null||_typeof(obj)!=="object"&&typeof obj!=="function"){return{"default":obj};}var cache=_getRequireWildcardCache(nodeInterop);if(cache&&cache.has(obj)){return cache.get(obj);}var newObj={};var hasPropertyDescriptor=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var key in obj){if(key!=="default"&&Object.prototype.hasOwnProperty.call(obj,key)){var desc=hasPropertyDescriptor?Object.getOwnPropertyDescriptor(obj,key):null;if(desc&&(desc.get||desc.set)){Object.defineProperty(newObj,key,desc);}else{newObj[key]=obj[key];}}}newObj["default"]=obj;if(cache){cache.set(obj,newObj);}return newObj;}function PostHogNavigationHook(_ref){var options=_ref.options,client=_ref.client;(0,_useNavigationTracker.useNavigationTracker)(options===null||options===void 0?void 0:options.navigation,client);return null;}function PostHogLifecycleHook(_ref2){var client=_ref2.client;(0,_useLifecycleTracker.useLifecycleTracker)(client);return null;}var isPromise=function isPromise(value){return value&&typeof value.then==='function';};var PostHogProvider=function PostHogProvider(_ref3){var children=_ref3.children,client=_ref3.client,options=_ref3.options,apiKey=_ref3.apiKey,autocapture=_ref3.autocapture,style=_ref3.style,_ref3$debug=_ref3.debug,debug=_ref3$debug===void 0?false:_ref3$debug;var _a,_b;var _useState=(0,_react.useState)(isPromise(client)?undefined:client),_useState2=(0,_slicedToArray2["default"])(_useState,2),posthog=_useState2[0],setPosthog=_useState2[1];var autocaptureOptions=(0,_react.useMemo)(function(){return autocapture&&typeof autocapture!=='boolean'?autocapture:{};},[autocapture]);var captureAll=autocapture===true;var captureNone=autocapture===false;var captureTouches=!captureNone&&posthog&&(captureAll||(autocaptureOptions===null||autocaptureOptions===void 0?void 0:autocaptureOptions.captureTouches));var captureScreens=!captureNone&&posthog&&(captureAll||((_a=autocaptureOptions===null||autocaptureOptions===void 0?void 0:autocaptureOptions.captureScreens)!==null&&_a!==void 0?_a:true));var captureLifecycle=!captureNone&&posthog&&(captureAll||((_b=autocaptureOptions===null||autocaptureOptions===void 0?void 0:autocaptureOptions.captureLifecycleEvents)!==null&&_b!==void 0?_b:true));(0,_react.useEffect)(function(){if(client&&apiKey){console.warn('You have provided both a client and an apiKey to PostHogProvider. The apiKey will be ignored in favour of the client.');}if(!posthog&&client){if(isPromise(client)){client.then(setPosthog);}else{setPosthog(client);}}else if(!posthog&&apiKey){_posthogRn.PostHog.initAsync(apiKey,options).then(setPosthog);}},[client,apiKey,posthog,options]);(0,_react.useEffect)(function(){if(!posthog){return;}posthog.debug(debug);},[debug,posthog]);var onTouch=(0,_react.useCallback)(function(type,e){if(!captureTouches){return;}if(type==='end'){(0,_autocapture.autocaptureFromTouchEvent)(e,posthog,autocaptureOptions);}},[captureTouches,posthog,autocaptureOptions]);return _react["default"].createElement(_reactNative.View,{"ph-label":"PostHogProvider",style:style||{flex:1},onTouchEndCapture:captureTouches?function(e){return onTouch('end',e);}:undefined,__self:_this,__source:{fileName:_jsxFileName,lineNumber:63,columnNumber:13}},_react["default"].createElement(_PosthogContext.PostHogContext.Provider,{value:{client:posthog},__self:_this,__source:{fileName:_jsxFileName,lineNumber:64,columnNumber:7}},_react["default"].createElement(_react["default"].Fragment,null,captureScreens?_react["default"].createElement(PostHogNavigationHook,{options:autocaptureOptions,client:posthog,__self:_this,__source:{fileName:_jsxFileName,lineNumber:66,columnNumber:29}}):null,captureLifecycle?_react["default"].createElement(PostHogLifecycleHook,{client:posthog,__self:_this,__source:{fileName:_jsxFileName,lineNumber:67,columnNumber:31}}):null),children));};exports.PostHogProvider=PostHogProvider;
@@ -1 +1 @@
1
- {"version":3,"file":"PostHogProvider.js","sourceRoot":"","sources":["../../../src/PostHogProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,EAAE,WAAW,EAAE,SAAS,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAA;AACxE,OAAO,EAAoC,IAAI,EAAa,MAAM,cAAc,CAAA;AAChF,OAAO,EAAE,OAAO,EAAkB,MAAM,cAAc,CAAA;AACtD,OAAO,EAAE,yBAAyB,EAAE,MAAM,eAAe,CAAA;AACzD,OAAO,EAAE,oBAAoB,EAAE,MAAM,8BAA8B,CAAA;AACnE,OAAO,EAAE,mBAAmB,EAAE,MAAM,6BAA6B,CAAA;AACjE,OA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CAAwB,EAAE,EAAE;QAC3D,+FAA+F;QAC/F,IAAI,CAAC,cAAc,EAAE;YACnB,OAAM;SACP;QAED,IAAI,IAAI,KAAK,KAAK,EAAE;YAClB,yBAAyB,CAAC,CAAC,EAAE,OAAO,EAAE,kBAAkB,CAAC,CAAA;SAC1D;IACH,CAAC,EACD,CAAC,cAAc,EAAE,OAAO,EAAE,kBAAkB,CAAC,CAC9C,CAAA;IAED,OAAO,CACL,CAAC,IAAI,CACH,QAAQ,CAAC,iBAAiB,CAC1B,KAAK,CAAC,CAAC,KAAK,IAAI,EAAE,IAAI,EAAE,CAAC,EAAE,CAAC,CAC5B,iBAAiB,CAAC,CAAC,cAAc,CAAC,CAAC,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,OAAO,CAAC,KAAK,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,CAEzE;MAAA,CAAC,cAAc,CAAC,QAAQ,CAAC,KAAK,CAAC,CAAC,EAAE,MAAM,EAAE,OAAO,EAAE,CAAC,CAClD;QAAA,EACE;UAAA,CAAC,cAAc,CAAC,CAAC,CAAC,CAAC,qBAAqB,CAAC,OAAO,CAAC,CAAC,kBAAkB,CAAC,CAAC,MAAM,CAAC,CAAC,OAAO,CAAC,EAAG,CAAC,CAAC,CAAC,IAAI,CAChG;UAAA,CAAC,gBAAgB,CAAC,CAAC,CAAC,CAAC,oBAAoB,CAAC,MAAM,CAAC,CAAC,OAAO,CAAC,EAAG,CAAC,CAAC,CAAC,IAAI,CACtE;QAAA,GACA;QAAA,CAAC,QAAQ,CACX;MAAA,EAAE,cAAc,CAAC,QAAQ,CAC3B;IAAA,EAAE,IAAI,CAAC,CACR,CAAA;AACH,CAAC,CAAA"}
@@ -1 +1 @@
1
- "use strict";var _interopRequireDefault=require("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(exports,"__esModule",{value:true});exports.getAppProperties=exports.buildOptimisiticAsyncStorage=void 0;var _regenerator=_interopRequireDefault(require("@babel/runtime/regenerator"));var _asyncToGenerator2=_interopRequireDefault(require("@babel/runtime/helpers/asyncToGenerator"));var _reactNative=require("react-native");var _OptionalAsyncStorage=require("./optional/OptionalAsyncStorage");var _OptionalExpoApplication=require("./optional/OptionalExpoApplication");var _OptionalExpoDevice=require("./optional/OptionalExpoDevice");var _OptionalExpoFileSystem=require("./optional/OptionalExpoFileSystem");var _OptionalExpoLocalization=require("./optional/OptionalExpoLocalization");var _OptionalReactNativeDeviceInfo=require("./optional/OptionalReactNativeDeviceInfo");var getAppProperties=function getAppProperties(){var deviceType='Mobile';if(_reactNative.Platform.OS==='macos'||_reactNative.Platform.OS==='windows'){deviceType='Desktop';}else if(_reactNative.Platform.OS==='web'){deviceType='Web';}var properties={$device_type:deviceType};if(_OptionalExpoApplication.OptionalExpoApplication){properties.$app_build=_OptionalExpoApplication.OptionalExpoApplication.nativeBuildVersion;properties.$app_name=_OptionalExpoApplication.OptionalExpoApplication.applicationName;properties.$app_namespace=_OptionalExpoApplication.OptionalExpoApplication.applicationId;properties.$app_version=_OptionalExpoApplication.OptionalExpoApplication.nativeApplicationVersion;}if(_OptionalExpoDevice.OptionalExpoDevice){properties.$device_manufacturer=_OptionalExpoDevice.OptionalExpoDevice.manufacturer;properties.$device_name=_OptionalExpoDevice.OptionalExpoDevice.modelName;properties.$os_name=_OptionalExpoDevice.OptionalExpoDevice.osName;properties.$os_version=_OptionalExpoDevice.OptionalExpoDevice.osVersion;}if(_OptionalExpoLocalization.OptionalExpoLocalization){properties.$locale=_OptionalExpoLocalization.OptionalExpoLocalization.locale;properties.$timezone=_OptionalExpoLocalization.OptionalExpoLocalization.timezone;}if(_OptionalReactNativeDeviceInfo.OptionalReactNativeDeviceInfo){properties.$app_build=returnPropertyIfNotUnknown(_OptionalReactNativeDeviceInfo.OptionalReactNativeDeviceInfo.getBuildNumber());properties.$app_name=returnPropertyIfNotUnknown(_OptionalReactNativeDeviceInfo.OptionalReactNativeDeviceInfo.getApplicationName());properties.$app_namespace=returnPropertyIfNotUnknown(_OptionalReactNativeDeviceInfo.OptionalReactNativeDeviceInfo.getBundleId());properties.$app_version=returnPropertyIfNotUnknown(_OptionalReactNativeDeviceInfo.OptionalReactNativeDeviceInfo.getVersion());properties.$device_manufacturer=returnPropertyIfNotUnknown(_OptionalReactNativeDeviceInfo.OptionalReactNativeDeviceInfo.getManufacturerSync());properties.$device_name=returnPropertyIfNotUnknown(_OptionalReactNativeDeviceInfo.OptionalReactNativeDeviceInfo.getDeviceNameSync());properties.$os_name=returnPropertyIfNotUnknown(_OptionalReactNativeDeviceInfo.OptionalReactNativeDeviceInfo.getSystemName());properties.$os_version=returnPropertyIfNotUnknown(_OptionalReactNativeDeviceInfo.OptionalReactNativeDeviceInfo.getSystemVersion());}return properties;};exports.getAppProperties=getAppProperties;var returnPropertyIfNotUnknown=function returnPropertyIfNotUnknown(value){if(value!=='unknown'){return value;}return null;};var buildOptimisiticAsyncStorage=function buildOptimisiticAsyncStorage(){if(_OptionalExpoFileSystem.OptionalExpoFileSystem){var filesystem=_OptionalExpoFileSystem.OptionalExpoFileSystem;return{getItem:function getItem(key){return(0,_asyncToGenerator2["default"])(_regenerator["default"].mark(function _callee(){var uri,stringContent;return _regenerator["default"].wrap(function _callee$(_context){while(1){switch(_context.prev=_context.next){case 0:uri=(filesystem.documentDirectory||'')+key;_context.prev=1;_context.next=4;return filesystem.readAsStringAsync(uri);case 4:stringContent=_context.sent;return _context.abrupt("return",stringContent);case 8:_context.prev=8;_context.t0=_context["catch"](1);return _context.abrupt("return",null);case 11:case"end":return _context.stop();}}},_callee,null,[[1,8]]);}))();},setItem:function setItem(key,value){return(0,_asyncToGenerator2["default"])(_regenerator["default"].mark(function _callee2(){var uri;return _regenerator["default"].wrap(function _callee2$(_context2){while(1){switch(_context2.prev=_context2.next){case 0:uri=(filesystem.documentDirectory||'')+key;_context2.next=3;return filesystem.writeAsStringAsync(uri,value);case 3:case"end":return _context2.stop();}}},_callee2);}))();}};}if(_OptionalAsyncStorage.OptionalAsyncStorage){return _OptionalAsyncStorage.OptionalAsyncStorage;}throw new Error('PostHog: No storage available. Please install expo-filesystem or react-native-async-storage OR implement a custom storage provider.');};exports.buildOptimisiticAsyncStorage=buildOptimisiticAsyncStorage;
1
+ "use strict";var _interopRequireDefault=require("@babel/runtime/helpers/interopRequireDefault");Object.defineProperty(exports,"__esModule",{value:true});exports.getAppProperties=exports.buildOptimisiticAsyncStorage=void 0;var _regenerator=_interopRequireDefault(require("@babel/runtime/regenerator"));var _asyncToGenerator2=_interopRequireDefault(require("@babel/runtime/helpers/asyncToGenerator"));var _reactNative=require("react-native");var _OptionalAsyncStorage=require("./optional/OptionalAsyncStorage");var _OptionalExpoApplication=require("./optional/OptionalExpoApplication");var _OptionalExpoDevice=require("./optional/OptionalExpoDevice");var _OptionalExpoFileSystem=require("./optional/OptionalExpoFileSystem");var _OptionalExpoLocalization=require("./optional/OptionalExpoLocalization");var _OptionalReactNativeDeviceInfo=require("./optional/OptionalReactNativeDeviceInfo");var getAppProperties=function getAppProperties(){var deviceType='Mobile';if(_reactNative.Platform.OS==='macos'||_reactNative.Platform.OS==='windows'){deviceType='Desktop';}else if(_reactNative.Platform.OS==='web'){deviceType='Web';}var properties={$device_type:deviceType};if(_OptionalExpoApplication.OptionalExpoApplication){properties.$app_build=_OptionalExpoApplication.OptionalExpoApplication.nativeBuildVersion;properties.$app_name=_OptionalExpoApplication.OptionalExpoApplication.applicationName;properties.$app_namespace=_OptionalExpoApplication.OptionalExpoApplication.applicationId;properties.$app_version=_OptionalExpoApplication.OptionalExpoApplication.nativeApplicationVersion;}if(_OptionalExpoDevice.OptionalExpoDevice){properties.$device_manufacturer=_OptionalExpoDevice.OptionalExpoDevice.manufacturer;properties.$device_name=_OptionalExpoDevice.OptionalExpoDevice.modelName;properties.$os_name=_OptionalExpoDevice.OptionalExpoDevice.osName;properties.$os_version=_OptionalExpoDevice.OptionalExpoDevice.osVersion;}if(_OptionalExpoLocalization.OptionalExpoLocalization){properties.$locale=_OptionalExpoLocalization.OptionalExpoLocalization.locale;properties.$timezone=_OptionalExpoLocalization.OptionalExpoLocalization.timezone;}if(_OptionalReactNativeDeviceInfo.OptionalReactNativeDeviceInfo){properties.$app_build=returnPropertyIfNotUnknown(_OptionalReactNativeDeviceInfo.OptionalReactNativeDeviceInfo.getBuildNumber());properties.$app_name=returnPropertyIfNotUnknown(_OptionalReactNativeDeviceInfo.OptionalReactNativeDeviceInfo.getApplicationName());properties.$app_namespace=returnPropertyIfNotUnknown(_OptionalReactNativeDeviceInfo.OptionalReactNativeDeviceInfo.getBundleId());properties.$app_version=returnPropertyIfNotUnknown(_OptionalReactNativeDeviceInfo.OptionalReactNativeDeviceInfo.getVersion());properties.$device_manufacturer=returnPropertyIfNotUnknown(_OptionalReactNativeDeviceInfo.OptionalReactNativeDeviceInfo.getManufacturerSync());properties.$device_name=returnPropertyIfNotUnknown(_OptionalReactNativeDeviceInfo.OptionalReactNativeDeviceInfo.getModel());properties.$os_name=returnPropertyIfNotUnknown(_OptionalReactNativeDeviceInfo.OptionalReactNativeDeviceInfo.getSystemName());properties.$os_version=returnPropertyIfNotUnknown(_OptionalReactNativeDeviceInfo.OptionalReactNativeDeviceInfo.getSystemVersion());}return properties;};exports.getAppProperties=getAppProperties;var returnPropertyIfNotUnknown=function returnPropertyIfNotUnknown(value){if(value!=='unknown'){return value;}return null;};var buildOptimisiticAsyncStorage=function buildOptimisiticAsyncStorage(){if(_OptionalExpoFileSystem.OptionalExpoFileSystem){var filesystem=_OptionalExpoFileSystem.OptionalExpoFileSystem;return{getItem:function getItem(key){return(0,_asyncToGenerator2["default"])(_regenerator["default"].mark(function _callee(){var uri,stringContent;return _regenerator["default"].wrap(function _callee$(_context){while(1){switch(_context.prev=_context.next){case 0:uri=(filesystem.documentDirectory||'')+key;_context.prev=1;_context.next=4;return filesystem.readAsStringAsync(uri);case 4:stringContent=_context.sent;return _context.abrupt("return",stringContent);case 8:_context.prev=8;_context.t0=_context["catch"](1);return _context.abrupt("return",null);case 11:case"end":return _context.stop();}}},_callee,null,[[1,8]]);}))();},setItem:function setItem(key,value){return(0,_asyncToGenerator2["default"])(_regenerator["default"].mark(function _callee2(){var uri;return _regenerator["default"].wrap(function _callee2$(_context2){while(1){switch(_context2.prev=_context2.next){case 0:uri=(filesystem.documentDirectory||'')+key;_context2.next=3;return filesystem.writeAsStringAsync(uri,value);case 3:case"end":return _context2.stop();}}},_callee2);}))();}};}if(_OptionalAsyncStorage.OptionalAsyncStorage){return _OptionalAsyncStorage.OptionalAsyncStorage;}throw new Error('PostHog: No storage available. Please install expo-filesystem or react-native-async-storage OR implement a custom storage provider.');};exports.buildOptimisiticAsyncStorage=buildOptimisiticAsyncStorage;
@@ -1 +1 @@
1
- {"version":3,"file":"native-deps.js","sourceRoot":"","sources":["../../../src/native-deps.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,MAAM,cAAc,CAAA;AACvC,OAAO,EAAE,oBAAoB,EAAE,MAAM,iCAAiC,CAAA;AACtE,OAAO,EAAE,uBAAuB,EAAE,MAAM,oCAAoC,CAAA;AAC5E,OAAO,EAAE,kBAAkB,EAAE,MAAM,+BAA+B,CAAA;AAClE,OAAO,EAAE,sBAAsB,EAAE,MAAM,mCAAmC,CAAA;AAC1E,OAAO,EAAE,wBAAwB,EAAE,MAAM,qCAAqC,CAAA;AAC9E,OAAO,EAAE,6BAA6B,EAAE,MAAM,0CAA0C,CAAA;AAGxF,MAAM,CAAC,MAAM,gBAAgB,GAAG,GAA+B,EAAE;IAC/D,IAAI,UAAU,GAAG,QAAQ,CAAA;IAEzB,IAAI,QAAQ,CAAC,EAAE,KAAK,OAAO,IAAI,QAAQ,CAAC,EAAE,KAAK,SAAS,EAAE;QACxD,UAAU,GAAG,SAAS,CAAA;KACvB;SAAM,IAAI,QAAQ,CAAC,EAAE,KAAK,KAAK,EAAE;QAChC,UAAU,GAAG,KAAK,CAAA;KACnB;IAED,MAAM,UAAU,GAA+B;QAC7C,YAAY,EAAE,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AC1B,MAAM,UAAU,GAAG,sBAAsB,CAAA;QACzC,OAAO;YACL,KAAK,CAAC,OAAO,CAAC,GAAW;gBACvB,MAAM,GAAG,GAAG,CAAC,UAAU,CAAC,iBAAiB,IAAI,EAAE,CAAC,GAAG,GAAG,CAAA;gBACtD,IAAI;oBACF,MAAM,aAAa,GAAG,MAAM,UAAU,CAAC,iBAAiB,CAAC,GAAG,CAAC,CAAA;oBAC7D,OAAO,aAAa,CAAA;iBACrB;gBAAC,OAAO,CAAC,EAAE;oBACV,OAAO,IAAI,CAAA;iBACZ;YACH,CAAC;YAED,KAAK,CAAC,OAAO,CAAC,GAAW,EAAE,KAAa;gBACtC,MAAM,GAAG,GAAG,CAAC,UAAU,CAAC,iBAAiB,IAAI,EAAE,CAAC,GAAG,GAAG,CAAA;gBACtD,MAAM,UAAU,CAAC,kBAAkB,CAAC,GAAG,EAAE,KAAK,CAAC,CAAA;YACjD,CAAC;SACF,CAAA;KACF;IAED,IAAI,oBAAoB,EAAE;QACxB,OAAO,oBAAoB,CAAA;KAC5B;IAED,MAAM,IAAI,KAAK,CACb,qIAAqI,CACtI,CAAA;AACH,CAAC,CAAA"}
@@ -24,8 +24,10 @@ export interface PostHogCustomAppProperties {
24
24
  $app_version?: string | null;
25
25
  /** Manufacturer like "Apple", "Samsung" or "Android" */
26
26
  $device_manufacturer?: string | null;
27
- /** Readable model name like "iPhone 12" */
27
+ /** Readable model name like "iPhone 12" or "Samsung Galaxy S24" */
28
28
  $device_name?: string | null;
29
+ /** Model identifier like "iPhone13,2" or "SM-S921B" */
30
+ $device_model?: string | null;
29
31
  /** Device type ("Mobile" | "Desktop" | "Web") */
30
32
  $device_type?: string | null;
31
33
  /** Operating system name like iOS or Android */
@@ -1 +1 @@
1
- export declare const version = "2.11.5";
1
+ export declare const version = "2.11.6";
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.version=void 0;var version="2.11.5";exports.version=version;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.version=void 0;var version="2.11.6";exports.version=version;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "posthog-react-native",
3
- "version": "2.11.5",
3
+ "version": "2.11.6",
4
4
  "main": "lib/posthog-react-native/index.js",
5
5
  "files": [
6
6
  "lib/"